Home > Web Front-end > JS Tutorial > body text

A simple JS mouse hover effect specific method_javascript skills

WBOY
Release: 2016-05-16 17:32:13
Original
1243 people have browsed it

First, you need to load the jquery library (skip).

Secondly, add the following Javascript code to the head of the page:

Copy the code The code is as follows:



No. Third, add to the style:
Copy code The code is as follows:

a {position: relative }

Done.

Simply define the a:hover style, which seems to be simpler:
Copy the code The code is as follows:

a:hover { padding: 0 0 0 8px;}

It’s just not natural enough.
Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!