Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 322
  • Last Modified:

Rollover with input type=image

I'd like to use a rollover effect with a graphic that I'm using with a <input type=image> tag. I know how to do it using <a href>, but I'd like to use it in a form instead. Can this be done, and if so, how?
0
JOK
Asked:
JOK
  • 2
  • 2
1 Solution
 
DeatheadCommented:
Unfortunately it cannot be doneusing the input tag..
a work around would be to make an href rollover and make it submit the form via javascript
<a href="#" onmouseover="change" onmouseout="changeback" onClick="document.formname.submit()"><img tag></a>

That will get the effect of what you want
X.Deathead
0
 
JOKAuthor Commented:
I was afraid of that. I'm working with code from someone else and it doesn't look like I can easily change the onClick code.

Oh well, thanks anyways.
0
 
DeatheadCommented:
if you post the code I could help you out...
0
 
JOKAuthor Commented:
What I've got works. But like I said, there's a bunch of stuff with the onClick now and I don't want to mess with it too much. Thanks anyways.
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

  • 2
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now