Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

status: 302 ERROR

Status
Not open for further replies.

madaxe2

Technical User
Jan 23, 2005
43
0
0
US


Status: 302 Moved location: ../index.html?error=1

Ive been trying to get this check script to work from an exec from a html page c below

Code:
<html>
<!--#exec cgi="CGI_BIN/CHECK.cgi"-->
</html>
Code:
#!/Perl/bin/perl -wT

use CGI qw(:standard);
use CGI::Carp qw(warningsToBrowser fatalsToBrowser);
use strict;

print "Content-type: text/html\n\n";

my $query = new CGI;
my $cookieinfo = $query->cookie('mcjeeves.net');

if (!$cookieinfo)
{
 
print $query->redirect("../index.html?error=1");

exit;

}
else
{
print $query->redirect("../homepage.html?error=1");
}

does anybody know why im getting this error


MadAXE
 
Remove:
print "Content-type: text/html\n\n";

When you redirect you can not print a content type because you are not printing anything!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top