---------- Forwarded message ----------
From: Jack Timmons <jorac...@gmail.com>
Date: Wed, Apr 22, 2009 at 9:41 AM
Subject: Re: [css-d] re: Styling submit buttons with images
To: Tom Dell'Aringa <pixelm...@gmail.com>


On Wed, Apr 22, 2009 at 9:35 AM, Tom Dell'Aringa <pixelm...@gmail.com> wrote:
> On Wed, Apr 22, 2009 at 9:32 AM, Jack Timmons <jorac...@gmail.com> wrote:
>
> Sorry, I'm probably being obtuse. I'm talking about the rollover effect.
> What I want to do is have an image submit button with a rollover, without
> using javascript. It would be nice if this would degrade for ie6 to still
> work. Fact is this is for a demo only on FF3, but I'm trying to look forward
> to when this hits production.
>
> Some people seem to suggest using the BUTTON element, but I'm not sure if
> this is a good way to go. (Is putting type=submit on a button element
> workable?)
>
> I just want a submit button, as an image, with a rollover - using CSS. The
> last time I tried this I ended up using JS for the rollover effect, which I
> don't want to do.
>
> Tom

Button elements -do- have a type='submit'. In FF, IIRC, it actually
defaults button tags to submit if no type is specified.

And, they support background CSS attributes.

http://www.htmldog.com/reference/htmltags/button/

== Message forwarded because I'm full of failure this morning. ==

So, obligatory code example!

<style type='text/css'>
button{background: url("fp.jpg");}
</style>
<button type='submit'>This is a button</button>

-- 
-Jack Timmons
http://www.trotlc.com
Twitter: @codeacula
______________________________________________________________________
css-discuss [cs...@lists.css-discuss.org]
http://www.css-discuss.org/mailman/listinfo/css-d
List wiki/FAQ -- http://css-discuss.incutio.com/
List policies -- http://css-discuss.org/policies.html
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/

Reply via email to