[Home]Show a new reply page after a form is submitted

HomePage | RecentChanges | Preferences | Newbie Help

Category HTML Forms

It depends upon the software that's processing the form. Some allow you to specify a URL to redirect to after submission, others have a fixed URL hard-coded. In any case, you have to consult the documentation that should have come with the software. Art Sackett

Precisely. There are different scenarios for each form based on the language processing it and the program that runs it. With PERL CGIs I use a simple statement to handle the next url.

    my $nexturl;

    if (!param('nexturl')) { # if there is no next url parameter specified
        warn "Error: No 'nexturl' param specified!";
        &too_bad; #subroutine which handles the event of no next url specified
    }else {
        $nexturl = param('nexturl');  # otherwise take us to the next url
    }

    print redirect($nexturl);
Within your HTML document it will look for the hidden parameter that specifys the 'nexturl'.

<input type="hidden" name="nexturl" value="thankyou.html">
-- A. MacNair Wed, 07 Mar 2001 08:04:18 GMT on al.html
Comments --

Don't forget to ask your ISP for instructions, if the form submission software is part of the ISP's package deal.


HomePage | RecentChanges | Preferences | Newbie Help
This page is read-only | View other revisions
Last edited January 9, 2002 7:51 am (diff)
Search:

This FAQ is happily hosted by Betadome Digital Media