Solved

python cgi redirect?

Posted on 2010-11-12
3
477 Views
Last Modified: 2012-05-10
how do i send a redirect to the browser from a cgi script?
0
Comment
Question by:wrynn
  • 2
3 Comments
 
LVL 15

Accepted Solution

by:
mish33 earned 500 total points
ID: 34129579
print "Status: 302 Moved\nLocation: NEW_URL\n\n"
0
 

Author Comment

by:wrynn
ID: 34278787
i have to print that without it being after printing the content type as html right?
0
 
LVL 15

Expert Comment

by:mish33
ID: 34279742
yes, don't print anything else
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Here I am using Python IDLE(GUI) to write a simple program and save it, so that we can just execute it in future. Because when we write any program and exit from Python then program that we have written will be lost. So for not losing our program we…
Dictionaries contain key:value pairs. Which means a collection of tuples with an attribute name and an assigned value to it. The semicolon present in between each key and values and attribute with values are delimited with a comma.  In python we can…
Learn the basics of strings in Python: declaration, operations, indices, and slicing. Strings are declared with quotations; for example: s = "string": Strings are immutable.: Strings may be concatenated or multiplied using the addition and multiplic…
Learn the basics of while and for loops in Python.  while loops are used for testing while, or until, a condition is met: The structure of a while loop is as follows:     while <condition>:         do something         repeate: The break statement m…

839 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