dcsimg
Login | Register   
RSS Feed
Download our iPhone app
TODAY'S HEADLINES  |   ARTICLE ARCHIVE  |   FORUMS  |   TIP BANK
Browse DevX
Sign up for e-mail newsletters from DevX

By submitting your information, you agree that devx.com may send you DevX offers via email, phone and text message, as well as email offers about other products and services that DevX believes may be of interest to you. DevX will process your information in accordance with the Quinstreet Privacy Policy.


Tip of the Day
Language: Web Development
Expertise: Beginner
Apr 23, 1999

WEBINAR:

On-Demand

Application Security Testing: An Integral Part of DevOps


Changing the Color of an Image Upon Mouseover

Question:
I'm designing a new rollover for my menu frame. I have five graphics, and I want them to change colors when the user mouses over them. Also, how do I make it so that text appears in the status bar at the bottom of the window?

Answer:
There are a couple of ways to make the images change colors when moused over. One example is to use a single tag and at least two different image files for the tag. You can use VBScript to change the value of the src property of the tag in the onmouseover and onmouseout events:




	

	

	

	








    
    



Adding text to the status bar is easy using the window object. The status property of the window object controls it. In this example, divBigStuff is a
tag. The text will appear in the status bar:
Sub divBigStuff_onmouseover
	window.status="Click here to see big stuff"
End Sub
DevX Pro
 
Comment and Contribute

 

 

 

 

 


(Maximum characters: 1200). You have 1200 characters left.

 

 

Sitemap
×
We have made updates to our Privacy Policy to reflect the implementation of the General Data Protection Regulation.
Thanks for your registration, follow us on our social networks to keep up-to-date