TheRedDeath
01-24-2009, 04:45 PM
I have a program with an form and an input that is an image. i want to be able to change the image after a function is activated but i dont know how to do this with javascript
function change(){
document.a.b.src = "something.jpg"
}
<form name="a">
<input name="b" type="image" src="x.x">
<input name="c" type="button" value="click" onclick="change()">
</form>
basically when that button is clicked i want that function to set the src to an actual image. Thanks in advance for any help
function change(){
document.a.b.src = "something.jpg"
}
<form name="a">
<input name="b" type="image" src="x.x">
<input name="c" type="button" value="click" onclick="change()">
</form>
basically when that button is clicked i want that function to set the src to an actual image. Thanks in advance for any help