Jump to content

chage tag class


dsci2000

Recommended Posts

Hi all,I've a problem with a simple (or seem so) html page.I've the follow javascript function defined in the head section:<script type="text/javascript" language="javascript">function changeclass(vid,cls){ document.getEelementById(vid).class=cls;}</script>In the html body I write the code <td class="titolotableft" id="tdhowto" align="left" onMouseOver="changeclass('howto','tdhover')" onMouseOut="changeclass('howto','titolotableft')"> <a>Come si fa...</a> </td>but when in the browser (IE) this not work.What's wrong?thanks for help.

Link to comment
Share on other sites

<html><head><script type="text/javascript" language="javascript">function changeclass(vid,cls){document.getEelementById(vid).className=cls;}</script></head><body><td class="titolotableft" id="tdhowto" align="left" onMouseOver="changeclass('howto','tdhover')" onMouseOut="changeclass('howto','titolotableft')"><a>Come si fa...</a></td></body></html>

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...