Reply to Re: How to view headers that are sent php4

Your name:

Reply:


Posted by ircmaxell on 03/09/07 07:58

On Mar 8, 9:47 pm, Toby A Inkster <usenet200...@tobyinkster.co.uk>
wrote:
> ircmaxell wrote:
> > I'm working on a php project modifying a CMS. I need to be able to
> > view the headers that the script is sending at runtime. In php5, I can
> > use headers_list(), but I'm using php4.
>
> You could try defining your own replacement for the header() function:
>
> function _header ($x)
> {
> $GLOBALS['HEADERS'][] = $x;
> header($x);
>
> }
>
> Wherever your code calls header(), replace it with _header(). Then you
> can use something like this:
>
> function _headers_list ()
> {
> return $GLOBALS['HEADERS'];
>
> }
>
> --
> Toby A Inkster BSc (Hons) ARCS
> Contact Me ~http://tobyinkster.co.uk/contact
> Geek of ~ HTML/SQL/Perl/PHP/Python*/Apache/Linux
>
> * = I'm getting there!

I would like to stay away from this for compatability reasons... I'm
modifying a popular CMS, and want to retain 3pd compatability. If it
was going to be just mine, I could just install a pecl package that
would give me the functionality needed... Thanks for your input...

[Back to original message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация