html - Bind multiple events in javascript -


i tried following change span red on mouseover , black on mouseout:

<span onmouseover="this.style.color='red' onmouseout=this.style.color='black'">mouse on me!</span> 

but not work!

how can bind more 1 event single element using javascript?

forgot quote..

<span onmouseover="this.style.color='red'" onmouseout="this.style.color='black'">mouse on me!</span>


Comments

Popular posts from this blog

android - MPAndroidChart - How to add Annotations or images to the chart -

javascript - Add class to another page attribute using URL id - Jquery -

firefox - Where is 'webgl.osmesalib' parameter? -