|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
Howdy all...
I'm using a form on a site, and one of the submit buttons calls a javascript function such as: <input type=button name=submit_button onClick="function();"> My question is, I would like to change the image of this button. I've tried: <input type=image src=images/picture name=submit_button onClick="function();"> This however doesn't seem to do the trick, without the type=button. If anyone can steer me in the right direction, or give me any help, I would be forever greatful... Thanks |
|
#2
|
||||
|
||||
|
You can put an onSubmit capture in the form tag and place your code there.
<form onsubmit="function()"> ------------------ Simon Wheeler FirePages -DHTML/PHP/MySQL |
|
#3
|
|||
|
|||
|
Internet Explorer recognizes a button tag. Just use it like this: <button>Button</button> The button tag supports most of the same attributes as other block elements, such as background images, size, visibility, etc... There's a really good tutorial about it at http://wsabstract.com/howto/button.shtml
(part 1 of 2). Sadly, netscape just ingnores the tag, so you have to embed hyperlinks in it to make it functional in that browser. |
|
#4
|
|||
|
|||
|
Hi! You can simply place image as submit button before the end of form end tag.
<input type="image" src="filename.gif"> This will act as submit button and take you to the header action in the form. you can modify you header if you need by placing another function call in onSubmit. Try this first. <BLOCKQUOTE><font size="1" face="Verdana,Arial,Helvetica">quote:</font><HR>Originally posted by puq: Howdy all... I'm using a form on a site, and one of the submit buttons calls a javascript function such as: <input type=button name=submit_button onClick="function();"> My question is, I would like to change the image of this button. I've tried: <input type=image src=images/picture name=submit_button onClick="function();"> This however doesn't seem to do the trick, without the type=button. If anyone can steer me in the right direction, or give me any help, I would be forever greatful... Thanks[/quote] [This message has been edited by marina (edited July 04, 2000).] |
![]() |
| Viewing: Dev Shed Forums > Web Design > JavaScript Development > Javascript form button |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|