Solved

Redirect

Posted on 1998-10-26
3
153 Views
Last Modified: 2013-12-25
Why isn't this script working:

print "Location: http://.../danke.asp\n\n";

The headers returned are:

HTTP/1.0 200 OK
Location: http://.../danke.asp
0
Comment
Question by:soeding
  • 2
3 Comments
 
LVL 2

Accepted Solution

by:
WileyKat earned 50 total points
Comment Utility
You need to use:

print "HTTP 301 Redirect\n\n";
print "Location: http://.../danke.asp";
0
 
LVL 1

Author Comment

by:soeding
Comment Utility
Thanks.
Easy, although it has to be:

print "HTTP 301 Redirect\n";
print "Location: http://.../danke.asp";

I just thought one could not add a header, when it was set - as in ASP.
0
 
LVL 2

Expert Comment

by:WileyKat
Comment Utility
Many CGIs return a Redirect header. Some also return 200 OK, 401 Access Forbidden, and 404 Not Found.
0

Featured Post

6 Surprising Benefits of Threat Intelligence

All sorts of threat intelligence is available on the web. Intelligence you can learn from, and use to anticipate and prepare for future attacks.

Join & Write a Comment

In this tutorial I will show you how to make a simple HTML bar chart with the usage of WhizBase, If you want more information about WhizBase please read my previous articles at http://www.experts-exchange.com/ARTH_5123186.html (http://www.experts-ex…
This article will show, step by step, how to integrate R code into a R Sweave document
The viewer will learn how to create and use a small PHP class to apply a watermark to an image. This video shows the viewer the setup for the PHP watermark as well as important coding language. Continue to Part 2 to learn the core code used in creat…
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …

744 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now