By hollybeary on
Ok, I'm having some trouble figuring this one out. Does anyone know how, or know of a good tutorial for how to use css to change the look and feel of the normal gray form submit buttons? I'm using the webform module. I need to replace the standard submit button with an image, and it also needs to have a rollover or hover effect. If I was just coding a standard static html page this would be so simple, but I'm not sure how to go about doing this the drupal way. Any suggestions? Thanks!
Comments
Got step 1
Ok, after some hunting around I've got half my problem answered. Using some styling magic:
I was able to change the button to an image, now all I need is a good way to get the image to change on a mouse hover. Thoughts anyone?
And We're Done :)
Final Solution, just add :hover
Turned out to be much easier than I thought! Hope this helps someone else down the road!
thanks
oh yes, it does helps :)
Solution
This is the solution I have been looking for. This absolutely works. I use css all the time, but before I saw this post, I had no idea that you could style your submit button with css. Thanks for the post.
Oh, and just a quick note. I use the webform module on my forms. For the submit button text, I had to enter spaces so that no text was sitting on top of my submit image. If you leave the normal, default value of your submit button alone (a blank value equates to the text 'Submit' for your button) or if you have entered alternate text for your submit button, the text will be sitting on top of your image--so spaces for this value work instead of text. These spaces assure you that you have no text ('Submit' or otherwise) covering your image.
Very Handy
~thanks
'(Òvó)
Just what I needed
Much thanks!