GeorgeMoney Posted August 24, 2006 Share Posted August 24, 2006 How do you make those "examples" like you see in many php things, like the comments are orange and strings are red and variables are blue and commands are green?Is there a predefined function to do this? or do you have to use a script? if so can someone show me?Sorry if this sounds a little stupid.Thanks in advance! Link to comment https://forums.phpfreaks.com/topic/18597-examples/ Share on other sites More sharing options...
hitman6003 Posted August 24, 2006 Share Posted August 24, 2006 GeSHi is often used for this:http://qbnz.com/highlighter/index.php Link to comment https://forums.phpfreaks.com/topic/18597-examples/#findComment-80102 Share on other sites More sharing options...
wildteen88 Posted August 25, 2006 Share Posted August 25, 2006 You can use highlight_string or highlight_file which will colour your PHP code, just the like forum does here:[code=php:0]<?phpecho "hello world";?>[/code] Link to comment https://forums.phpfreaks.com/topic/18597-examples/#findComment-80322 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.