Re: PHP source display

From: Date: Sun, 12 Oct 2003 06:16:29 +0000
Subject: Re: PHP source display
References: 1 2  Groups: php.general 
Request: Send a blank email to php-general+get-165879@lists.php.net to get a copy of this message
The functions Ryan is talkink about are show_source, highlight_file, and highlight_string, but they're a bit more work than getting *.phps files to work. I'm no apache wizard, and I don't know what's going on with the SetOutputFilter type stuff, but it's not what's in the manual at all. Take a look at http://www.php.net/manual/en/install.apache2.php If you really want the stuff you've got below, perhaps php-source? That's just a guess, though... Remember, Apache 2 w/ PHP is not recommended for productions boxes (IIRC, although PHP itself is thread safe, code the extensions bring in may not be. You probably won't have any problems, but no guarantees). Good luck! On Friday 10 October 2003 12:56 pm, Ryan Thompson wrote: > Try using the function view_source(string filename) > That's off the top of my head. Might be wrong. It's in the documentation > > On Friday 10 October 2003 15:41, Lists wrote: > > When I used apache 1.3 I could call a file with an extension of .phps and > > it would display formatted source. > > > > In apache 2.0 it does not do this > > > > Here is my config from apache 2.0 > > > > > > LoadModule php4_module modules/libphp4.so > > > > # > > # Cause the PHP interpreter handle files with a .php extension. > > # > > <Files *.php> > > SetOutputFilter PHP > > SetInputFilter PHP > > LimitRequestBody 524288 > > </Files> > > > > I have tried doing: > > > > <Files *.phps> > > SetOutputFilter PHPS > > SetInputFilter PHPS > > LimitRequestBody 524288 > > </Files> > > > > > > However, that does not work! > > > > Any ideas? > > > > Michael -- Evan Nemerson evan@coeus-group.com -- "If there is no higher reason--and there is none--then my own reason must be the supreme judge of my life." -Leo Nikolaevich Tolstoy

« previous php.general (#165879) next »