aspose file tools*
The moose likes HTML, CSS and JavaScript and the fly likes OnMouseover Change text color. Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "OnMouseover Change text color." Watch "OnMouseover Change text color." New topic
Author

OnMouseover Change text color.

Patricia Samuel
Ranch Hand

Joined: Sep 12, 2007
Posts: 300
Hello All,

I have a tag

& lt;span on mouse over="callfunction" class="text"& gt;textstring
& lt;/span& gt;



I want to change "textstring" color whenever user mouse over on it.can anyone help me to sort out this petty problem.

And also , i am getting some problem in posting this topic. It shows me some html related tag problems. I appreciate if some one could tell me how to post HTML code.


Thanks to All.
Have a Good Day!

-Patricia
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61421
    
  67

Originally posted by Patricia Samuel:

& lt;span on mouse over="callfunction" class="text"& gt;textstring
To invoke a function as an event handler:
And also , i am getting some problem in posting this topic

For security reasons, the forum code will filter out certain JavaScript phrases. The phrase "eval" and most of the "onwhatever" event attributes will trigger the filter.

To get around the filter, substitute the HTML entity for some characters in the phrase. For example, o for 'o'.
[ February 24, 2008: Message edited by: Bear Bibeault ]

[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61421
    
  67

P.S. If you are only concerned with modern browsers, you can do this with CSS and no JavaScript.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: OnMouseover Change text color.