Click here to Skip to main content
15,892,797 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I have one Html image in my page.I want to set the background image to that image on mouse over. I tryed a lot but, i did't get please let me know if you know the solution
Posted

1 solution

Not sure, but give it a try :)
JavaScript
<div>
  <a href="tom.jpg">
    <img src="http://www.wmagency.co.uk/wp-content/uploads/2011/04/test.jpg">
         onmouseover='document.getElementById("table_id_here").style["background-image"]="url(\'jerry.jpg\');'
         width="72" height="54" alt="" />
  </img></a>
</div>
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900