in reply to CGI question: elegant way to have three form image buttons doing different things?


Please don't listen to the folks who recommend using java script!
If you concentrate on perl (and this is a 'about perl'
site) you can use the server sided script even with
lynx or GUI oriented Browsers without java script
being enabled.
Keep using the smallest common type of functions if
possible.

--
there are no silly questions
killerhippy
  • Comment on Re: CGI question: elegant way to have three form image buttons doing different things?

Replies are listed 'Best First'.
Re: Re: CGI question: elegant way to have three form image buttons doing different things?
by willdooUK (Beadle) on Sep 14, 2001 at 16:50 UTC
    also re: Please don't listen to the folks who recommend using java script!

    I'm not convinced.

    While you're right that its good to keep to the least complicated solution possible, in this case I think JS is a good choice.

    Since Lynx is a text-only browser, the original HTML wouldn't work - meonkeys wanted "an HTML form with three different images that do three different actions". He wanted three images to submit the form in three different ways.

    Also, since we're talking about forms with text input, its already prejudiced against GUI browsers (like a touch-screen info station, presumably). You could code for non-keyboard devices, but I'd only do it if I really had to.

    Surely it makes sense to utilise the best technologies at our disposal? I use Perl because it lets me make dynamic server side code with the least fuss. I use Javascript because it lets me make the client side dynamic with the least fuss.

    willdooUK
    --------------
    "Home is a castle you built in my mind; I'm home anywhere, anytime."
    Donny Hathaway
Re: Re: CGI question: elegant way to have three form image buttons doing different things?
by mrmick (Curate) on Sep 14, 2001 at 16:46 UTC
    re: Please don't listen to the folks who recommend using java script!

    Although this site is about Perl, we all have to realize that it's not always the 'best' solution to a particular problem. We have to use what is best suited for a particular task.

    I really don't like when someone say's not to listen to someone simply because they disagree. Let's keep our minds open and take advice from all, even those who we don't necessarily agree with.

    Personally, I would have gone for the javascript solution only because I know that the clients we support here are javascript enabled. However, if I am pointed to a better solution, I keep an open mind am likely to use it if I deem it appropriate.

    Mick
Re: Re: CGI question: elegant way to have three form image buttons doing different things?
by khippy (Scribe) on Sep 16, 2001 at 03:52 UTC
    Ok, here I am replying to myself, because mrmick and willdooUK
    are right in their sight and, of course, meonkeys approach.
    Let's say I was small-minded, when writing this. I was trapped
    by the imagination of an application of my own, instead of
    having read everything *before* answering (which was to be use-
    able by lynx, but later on, it couldn't work that way, but I
    am still aiming to that).
    Furthermore the experience of new websites, mixing their
    html-code with java-script e.g. to make a download-button, which
    disables copying the download-target, and other "modern" stuff,
    which might be functional but break my habbit of using things
    caused me to be angry about that.
    I was transporting this problem to the question of meonkeys,
    which was not ok, ok!
    Maybe I am answering better next time :)

    --
    there are no silly questions
    killerhippy