Super, always pleased to learn new stuff.

So what is happening is that the CGI.pm is sending headers to Apache to send back to the client. However Apache notices that the status is 200 and that there is a Location header and decides to issue a new request through itself for this location. So until the new location's data is grabbed and is ready to go back nothing is sent to the client making this an internal, as opposed to external, redirect.

So without forcing a status of 200 CGI.pm redirect would send back a status of 302 (Moved Temporarily) which Apache would send on to the brower to deal with.

I believe I am clear an this now, thanks for the clarification.


In reply to Re: •Re: Re: Re: cgi redirect (again) by EvdB
in thread cgi redirect (again) by The_Rev

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.