Jump to content

How to print color formatted PHP code


mallen

Recommended Posts

just style it with css as you would normally. you can add styles to H tags, span tags, etc.

 

so for example:

 

echo '<h4 style="color:red;"> text here </h4>';

or

echo '<h4 style="color:red;">'. $variable. '</h4>';

 

Well yeah I could but I know for example there is a plug in for WordPress that allows you to do make it look like this

http://www.free-php.net/830/wordpress-custom-field-image-to-featured-image/

 

but I am not using WordPress. I know this board uses Code tags.  This is what they are using http://alexgorbatchev.com/SyntaxHighlighter/manual/brushes/php.html

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.