By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,963 Members | 1,259 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,963 IT Pros & Developers. It's quick & easy.

how to add mouse over and out events to change image of anchor tag ?

P: 1
how to add mouse over and out events to change image of anchor tag ?
Dec 17 '13 #1
Share this Question
Share on Google+
2 Replies


Dormilich
Expert Mod 5K+
P: 8,639
like any other event. e.g. by using addEventListener()
Dec 17 '13 #2

P: 10
Expand|Select|Wrap|Line Numbers
  1. **stylesheet code**
  2. #aCollection
  3. {
  4.     background-image: url('images/collection.jpg');
  5. }
  6. #aCollection:hover
  7. {
  8.     background-image: url('images/collection_hover.jpg');
  9. }
  10.  
  11. #aCollection:active
  12. {
  13.     background-image: url('images/collection_active.jpg');
  14. }
Thanks
Jeff Jones
Dec 17 '13 #3

Post your reply

Sign in to post your reply or Sign up for a free account.