Re: syntax highlighting your php code on a web page

From: Date: Thu, 04 Aug 2005 16:34:47 +0000
Subject: Re: syntax highlighting your php code on a web page
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-220019@lists.php.net to get a copy of this message
* Steve Turnbull <sturnbull@yhgfl.net>: > Is there a class or some code out there which enables you to print your > PHP code to a web page and make it appear with syntax highlighting? > > As an example of what I am after, have a look here; > > http://www.phpfreaks.com/phpmanual/page/function.ldap-add.html > > Please note this is just an example page which highlights what I am after... There's a few ways. highlight_file() and highlight_string() will do it. Another way is to symlink to the .php file as extension .phps -- and provide a link to the .phps file. -- Matthew Weier O'Phinney Zend Certified Engineer http://weierophinney.net/matthew/

« previous php.general (#220019) next »