Solved

CGI Form variables and Location: header

Posted on 1998-04-15
3
214 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 100 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

MIM Survival Guide for Service Desk Managers

Major incidents can send mastered service desk processes into disorder. Systems and tools produce the data needed to resolve these incidents, but your challenge is getting that information to the right people fast. Check out the Survival Guide and begin bringing order to chaos.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
How does Redux fit into React? 3 91
exchange ,script 10 54
Powershell File Sort 8 45
BatchFile-Disk Detection 23 25
I hope you'll find this tutorial useful and interesting. So let's try to extend Tcl with a new package.  For anyone more deeply interested please check out the book "Practical Programming in Tcl and Tk". It's really one of the best written books abo…
It is a general practice to get rid of old user profiles on a computer  in a LAN environment. As I have been working with a company in a LAN environment where users move from one place to some other place at times. This will make many user profil…
The viewer will learn how to dynamically set the form action using jQuery.
The viewer will learn how to count occurrences of each item in an array.

756 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