in reply to Re: [CGI] redirect after headers have been printed
in thread [CGI] redirect after headers have been printed

Why do you need to do that ?

Simple -- you have a website that uses cookies for authentication. It senses someone's not logged in, and sends them to a login form. The form submits to a page -- that sets the necessary cookies, and then redirects them back to the page they originally attempted to access.

Yes, there are other ways of doing this, but when the majority of your pages and other items (images, video, etc.) are static, it doesn't make sense to place the whole thing between a heavyweight CMS.

Yes, this might be an XY Problem, but I've had the same problem before, when tool authors assume that this feature would never be needed, and yet it makes perfect sense to me.

  • Comment on Re^2: [CGI] redirect after headers have been printed