Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Javascript customize button

Status
Not open for further replies.

HigherHigher

IS-IT--Management
Feb 7, 2005
37
CA
I am making a customize button to replace the standard button and I don't know how. Please help. The code is below. Thank you for your time.

<FORM name=font_select action=GET><INPUT onclick=javascript:fontsizedown(); type=button value=" font - ">
<INPUT onclick=javascript:fontsizeup() type=button value=" font + "> </FORM>
 

What does your code not do that you want it to do?

What do you mean when you say you want to create a "customize button"? Do you mean a button that lets users customise their web page, or something else?

What do you actually want to achieve?

Dan


[tt]D'ya think I got where I am today because I dress like Peter Pan here?[/tt]
[banghead]

 
The above Javascript creates the standard button. Right? I want to replace the standard button with a smaller button.

Yes. The button lets users customize their web page by resizing the font size. I use the script from
 
I know how to create buttons using CSS but I don't know how to incorporate this with Javascript and make it workable. Does this make any sense to you?
<INPUT onclick=javascript:fontsizedown(); type=button value=" font - ">
 
That still creates a standard button.
If you go ABC website and look at the font size button on your right, I want to create something like that.
I used this Javascript from and I was unable to achieve this by using src="image/button.gif" on the Javascript. I don't see my customized button on but the standard button on the web page. Any thoughts?
 
Try this- first download two example buttons from me on the web,from: and: saving them to the same file as your HTML page is in, naming them as: "go1.gif" and "go2.gif" respectively. Then go to your HTML page to the line: <INPUT onclick=javascript:fontsizeup() type=button value=" font + "> and remove it and change it to: <a href=javascript:; onclick="fontsizeup()"><img border="0" src="go1.gif" width="20" height="15" onmouseover="this.src="go2.gif"
onmouseout="this.src="go1.gif"></a>
Of course you will want to make you own images the size you want with the text "font +" drawn right onto the image, using your painting program. If this is close, let me know!
Programatically,
Classefied
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top