WebProWorld Part of WebProNews.com
Page One Link To Us Edit Profile Private Messages Archives FAQ RSS Feeds  
 

Go Back   WebProWorld > Site Design > Graphics & Design Discussion Forum
Subscribe to the Newsletter FREE!


Register FAQ Members List Calendar Arcade Chatbox Mark Forums Read

Graphics & Design Discussion Forum Post your graphics design questions/comments/ideas in here. Ask questions, post tutorials, discuss trends and best practices. Sub-forum for website accessibility and usability.

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 01-31-2004, 06:34 PM
WebProWorld Pro
 

Join Date: Jan 2004
Location: Milton Keynes, UK
Posts: 117
DarrenPWS RepRank 0
Default Submit Buttons

Hi all,
I would like to have an onMouseOver / hover effect on my submit button images.

Can any of you give me that code???

Thanks a lot,
DD
Reply With Quote
  #2 (permalink)  
Old 01-31-2004, 06:44 PM
ranjan's Avatar
WebProWorld Pro
 

Join Date: Sep 2003
Location: CA
Posts: 174
ranjan RepRank 0
Default

define two classes in your style sheet

Code:
.oldclass {
	background-color:#ccc;
        background-image: url(pic.gif);
	color:#333;
}
.newclass {
	background-color:#333;
        background-image: url(pic_over.gif);
	color:#ccc;
}
now any input tag that contains the following code

Code:
<input class="oldclass" type="submit" name="Submit" value="Submit" onmouseover="this.className='newclass';" onmouseout="this.className='oldclass';">
will have a mouse over effect. The pic.gif is normal state and pic_over.gif is hover state images resp.
__________________
ranjan | Macromedia Certified Dreamweaver MX Developer
http://www.dreamlettes.net - a dreamweaver resource
http://www.ranjan.ws - got blog?
http://www.total-impact.com - a web design community
Reply With Quote
  #3 (permalink)  
Old 01-31-2004, 06:54 PM
WebProWorld Pro
 

Join Date: Jan 2004
Location: Milton Keynes, UK
Posts: 117
DarrenPWS RepRank 0
Default Thanks..

Hi Ranjan,

Thanks for that code, it was exaclty what I was after !! :D

Sorry for cross posting - it was selfish, but I am working on the form now and was desperate for the help - Thanks again,

DD
Reply With Quote
Reply

  WebProWorld > Site Design > Graphics & Design Discussion Forum
Tags: ,



Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Search Engine Optimization by vBSEO 3.2.0