Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid
 
PerlMonks  

Re: POST from a hyperlink

by TwistedGreen (Sexton)
on Apr 25, 2004 at 18:22 UTC ( [id://347991]=note: print w/replies, xml ) Need Help??


in reply to POST from a hyperlink

You should know that you can also use CSS to change your submit button to look like whatever you want: change its colours or borders, or replace it with another image entirely.

Replies are listed 'Best First'.
Re: Re: POST from a hyperlink
by Anonymous Monk on Apr 25, 2004 at 20:38 UTC
    <input type="image" src="/whatever.gif"> will also work and doesn't require CSS (not that CSS is a bad thing, just that an image input is simpler).
      It also won't submit the form as written. Using anything other than an input of type "submit" will not submit a form without some form of client-side scripting, usually JavaScript.

      As for CSS, using CSS provides a lot more, and should be recommended in general.

      ------
      We are the carpenters and bricklayers of the Information Age.

      Then there are Damian modules.... *sigh* ... that's not about being less-lazy -- that's about being on some really good drugs -- you know, there is no spoon. - flyingmoose

        Good to be aware of that. JavaScript isn't something I want to enclude a lot of so its good to know these form's limitations.
        I generally use CSS and find it very handy. I'm glad there is a way to apply button images in both HTML and CSS. Thanks for your input. Joe
        A reply falls below the community's threshold of quality. You may see it by logging in.

      It might be simpler, but maybe I'm using a terrible old and slow modem and on top of that, it takes too many hops to reach your server. In that case, I can switch off CSS and get the default submit button, instead of downloading your whatever.gif, what should be a whatever.jpeg or whatever.png to begin with ;-)

      And another nice advantage of the CSS approach is that maybe in a month time you like to restyle your website and you have a new whatever image. The bad thing is that you were cheap and chose a webhosting company that only allows you to use FTP (yeah, they are out there ;-) Now you need to download all the files that contain the reference to this image, change them and upload them again. With the CSS approach, you simple alter the CSS file and upload that one.

      --
      b10m

      All code is usually tested, but rarely trusted.
        That's interesting. I never really thought of CSS as a layer that you could shut off for slower connections. I should try that at home sometime with my modem. Thanks for your input. Joe
      That's a good shortcut. Seems easy to implement. Thanks for the tip. Joe
Re: Re: POST from a hyperlink
by JoeJaz (Monk) on Apr 25, 2004 at 20:53 UTC
    Neat! You learn someting new every day. That would certainly solve my form uglieness problem. Thanks for the info. Joe

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://347991]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others studying the Monastery: (3)
As of 2024-04-19 01:13 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found