Re: Highlighted Syntax

From: Date: Fri, 23 Jun 2000 07:07:54 +0000
Subject: Re: Highlighted Syntax
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-2753@lists.php.net to get a copy of this message
On 23 Jun, Andrew Braund wrote: > <? > show_source("filename"); > ?> > Takes the source from a file and displays a coloured up version on your > browser. You may have save your MySQL output to a file first, but I'm > sure someone else will have a better way of doing it. > > > Note: I have tried this on WinNT and it works. On Win95 or Win98 is does > not work. I get the message; > > Warning: Failed opening 'c:\\htdocs\\examples\\php\\info.php' for > highlighting in c:\htdocs\examples\php\info.php on line 28 > > Any ideas why this is happening? > > Regards > Andrew Braund This is in the (PDF) docs for PHP: To use the source code highlighting feature, simply create a PHP script file and stick this code in: <?php show_source ("original_php_script.php3"); ?>. Substitute original_php_script.php3 with the name of the file you wish to show the source of. (this is only one way of doing it). Note: On Win-Apache all back slashes in a path statement such as: "c:\directory\file.ext", must be converted to forward slashes. Might be the problem? Cheers -- David Robley | WEBMASTER & Mail List Admin RESEARCH CENTRE FOR INJURY STUDIES | http://www.nisu.flinders.edu.au/ AusEinet | http://auseinet.flinders.edu.au/ Flinders University, ADELAIDE, SOUTH AUSTRALIA

« previous php.general (#2753) next »