...

View Full Version : PHP Coloring?



Rappa
08-06-2007, 08:13 PM
I didnt really know what to call this thread, so i figured PHP coloring, although vague, represents what im about to ask.

You know the way the code gets formatted on these forums, when its put between [PHP] tags, like all the different elements get different colors.

I was wondering if there was anyway I could implement that on my site. Like i post some code and it automaticlly does that for me.

Any help would be nice.

matak
08-06-2007, 08:53 PM
higlight string


<?php
$str= "<?php
echo \"Hello world!\";
?>";
echo highlight_string ($str, 'true' );
?>

Also escape $ if you have one.. (\$)

Rappa
08-06-2007, 09:23 PM
awesome thanks, ill give it a try!



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum