in reply to Preventing GET and POST from getting mixed-up

Disclaimer: this is all IMHO :)

Really, I think the most correct way is to not mix GET and POST methods. If you need to pass parameters to your script along with your form then pass them as hidden fields with your POST and if you're using GET, just use URLs. That way you can use the $ENV{REQUEST_METHOD} to know how your user accessed the script, and still do whatever you need to with the named parameters. Really, what difference does it make how they were passed to the script?

Again IMHO

Lobster Aliens Are attacking the world!

Replies are listed 'Best First'.
Re: Re: Preventing GET and POST from getting mixed-up
by xaphod (Monk) on Aug 19, 2003 at 14:48 UTC

    Disclaimer: this is all IMHO :)

    Well, your opinion is perfectly valid, and in that past that's how I've done things (eventually I may giveup on this particular intellectual challenge and just do it as you suggest). But, if possible, I'd like to avoid the need to specify an action in my forms, having my form POSTed to the current URL, which may (or may not) include GET vars.

    --
    TTFN, FNORD

    xaphod