homepage Welcome to WebmasterWorld Guest from
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Become a Pro Member
Home / Forums Index / Code, Content, and Presentation / Perl Server Side CGI Scripting
Forum Library, Charter, Moderators: coopster & jatar k & phranque

Perl Server Side CGI Scripting Forum

Displaying a custom page if procedure fails

10+ Year Member

Msg#: 3426 posted 9:38 pm on Jan 19, 2004 (gmt 0)

I have a simple form on my website which requires the person viewing the page to input their details. Once input they hit the "Go" button and are taken to another screen where they can download the program. At this point I would be sent an email containing their details. What is now happening quite frequently (due apparently to a temporary overload at my webhost) is that they see a "Page not found screen".

The "Go" button is linking to :-


What I would prefer to happen is if the procedure fails then rather than the "Page not found screen" appearing the person viewing the site would see another screen with a button on which links directly to my download file. This way I would lose the personal details of the person but they could still download the program. I would much prefer this situation than them see a "Page not found screen" and perhaps dissapear forever.

Has anyone any idea how this could be done?




WebmasterWorld Senior Member 10+ Year Member

Msg#: 3426 posted 2:57 pm on Jan 20, 2004 (gmt 0)

I can't see a way of doing it direct from your script, as by the time the error page appears control has been passed from your script to the server.

However, .htaccess files can be placed in any directory and will apply only to that directory and any below it. Maybe you could set up a custom 404 page just for your cgi-bin, with the direct download link on it?

Global Options:
 top home search open messages active posts  

Home / Forums Index / Code, Content, and Presentation / Perl Server Side CGI Scripting
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved