?
Solved

CGI Form variables and Location: header

Posted on 1998-04-15
3
Medium Priority
?
219 Views
Last Modified: 2013-12-25
Is there a limit to the length of a CGI form variable when using the Location: header?  I have a textarea that contains over 8K of data.  The data gets truncated when it reaches the cgi script that is called like; Location:http://hostname/script.cgi?name=value.....
0
Comment
Question by:wspoulin
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 1

Accepted Solution

by:
OM earned 200 total points
ID: 1832279
It depends of your OS. The query string is passed by environment
variables.

I suspect that this is the output of a CGI. Why do use a Location
if you need to call another CGI ? If it is not yours, better
call it and pass the returned value as result of your CGI.
0
 

Author Comment

by:wspoulin
ID: 1832280
So, the Location tag uses the get method which uses environment variables to pass everything after the ?.  Is this correct?  I have to use Location I believe.  How can I call  a cgi script from a cgi script without using it? I have to hand this data from one script to the other and the last script actually hands it off to one more!  Is there a way to use a POST method with Location?
0
 
LVL 1

Expert Comment

by:OM
ID: 1832281
In HTTP/1.0 nothing is specified, but in HTTP/1.1 recommandation, it is stated that :
     Note: When automatically redirecting a POST request after receiving
     a 301 status code, some existing HTTP/1.0 user agents will
     erroneously change it into a GET request.


Unfortunately, every browser I tested do this error.
So, the response is :
      no in HTTP/1.0 with current browser.
      yes in HTTP/1.1

The only way I see to turn around this is to call from the first
CGI the second one, then to return the values from the second one.
In a modern langage (Python for example, or of course in Java,
C, C++, ..) it is not so difficult.


0

Featured Post

Stressed Out?

Watch some penguins on the livecam!

Question has a verified solution.

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

If you get a (Blue Screen of Death), your system writes a small file called a minidump. Your first step is to make certain your computer is setup to record memory dumps. Right click My Computer, choose properties. Click on the advanced tab, an…
Batch, VBS, and scripts in general are incredibly useful for repetitive tasks.  Some tasks can take a while to complete and it can be annoying to check back only to discover that your script finished 5 minutes ago.  Some scripts may complete nearly …
Learn the basics of modules and packages in Python. Every Python file is a module, ending in the suffix: .py: Modules are a collection of functions and variables.: Packages are a collection of modules.: Module functions and variables are accessed us…
In this fifth video of the Xpdf series, we discuss and demonstrate the PDFdetach utility, which is able to list and, more importantly, extract attachments that are embedded in PDF files. It does this via a command line interface, making it suitable …
Suggested Courses

762 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