Quote:
|
Originally Posted by Raven_Writer
I'm not excellent in PHP, but I'm pretty sure there's a way to search for certain strings, and if it's found, just color-code it. Kinda like:
PHP Code:
$text = strtext("$filename");
if($text){
explode("void", "<font color='#0000FF'>void</a>");
}
(I highly doubt strtext(...) works, it's just something that came to me
|
Why are you using explode?
Check
http://us3.php.net/manual/en/function.eregi-replace.php
You have to know regular expressions, but it's the quickest and most flexible way to do it.
Just search for the keywords and replace them when you read the file into a variable...it shouldn't be too tough.