Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Perl > Perl Misc > Difference between redirects

Reply
Thread Tools

Difference between redirects

 
 
googleid2003@yahoo.com
Guest
Posts: n/a
 
      01-22-2005
I know nothing about perl, so a friend of mine wrote a cgi script for
me to do a redirect on my website based on user input from a html form
using a variable $userName. The piece of code that does this:

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

print "<html><head><meta http-equiv=\"refresh\"
content=\"0;url=$path$userName\"></head><body></body>\n";

What's the pros/cons, if any, or difference between this and the
following:

print "Location: http://www.somesite.com/directory/$userName\n\n";

They seem to do the same thing, and I wonder which is "better".
Thanks,
Mike

 
Reply With Quote
 
 
 
 
A. Sinan Unur
Guest
Posts: n/a
 
      01-22-2005
http://www.velocityreviews.com/forums/(E-Mail Removed) wrote in news:1106424985.003262.168740
@c13g2000cwb.googlegroups.com:

> I know nothing about perl, so a friend of mine wrote a cgi script for
> me to do a redirect on my website based on user input from a html form
> using a variable $userName. The piece of code that does this:
>
> print "Content-type:text/html\n\n";
> print "<html><head><meta http-equiv=\"refresh\"
> content=\"0;url=$path$userName\"></head><body></body>\n";
>
> What's the pros/cons, if any, or difference between this and the
> following:
>
> print "Location: http://www.somesite.com/directory/$userName\n\n";


This is not a Perl question. It is a CGI question. As such, it is off-
topic here. You'll better off posting it to a CGI group such as
comp.infosystems.www.authoring.cgi

See also http://cgi-spec.golux.com/cgi-120-00a.html#8.0

Sinan.
 
Reply With Quote
 
 
 
 
googleid2003@yahoo.com
Guest
Posts: n/a
 
      01-22-2005
Sorry about that. Thanks for the info.

A. Sinan Unur wrote:
> (E-Mail Removed) wrote in news:1106424985.003262.168740
> @c13g2000cwb.googlegroups.com:
>
> > I know nothing about perl, so a friend of mine wrote a cgi script

for
> > me to do a redirect on my website based on user input from a html

form
> > using a variable $userName. The piece of code that does this:
> >
> > print "Content-type:text/html\n\n";
> > print "<html><head><meta http-equiv=\"refresh\"
> > content=\"0;url=$path$userName\"></head><body></body>\n";
> >
> > What's the pros/cons, if any, or difference between this and the
> > following:
> >
> > print "Location: http://www.somesite.com/directory/$userName\n\n";

>
> This is not a Perl question. It is a CGI question. As such, it is

off-
> topic here. You'll better off posting it to a CGI group such as
> comp.infosystems.www.authoring.cgi
>
> See also http://cgi-spec.golux.com/cgi-120-00a.html#8.0
>
> Sinan.


 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Make Process IO Redirects persist between pages Evan ASP .Net 1 02-19-2008 12:42 PM
difference between between these "char"s arnuld C++ 33 03-05-2007 03:11 PM
Session Variables Not Being Saved Between Page Redirects Hanover ASP .Net 2 09-08-2005 06:19 PM
Difference between bin and obj directories and difference between project references and dll references jakk ASP .Net 4 03-22-2005 09:23 PM
Exact difference between 'const char *' and 'char *', also diff between 'const' and 'static' Santa C Programming 1 07-17-2003 02:10 PM



Advertisments