Hello and thanks for any help, I have a long test string and the string looks like
1) 01 1 20080617 20:01 00260 0
2) 01 1 20080617 07:11 00126 0
3) 01 1 20080616 17:50 00292 0
4) 01 1 20080616 06:51 00122 0
When I want to highlight 01 then I only want to highlight a whole "string from space to space and not all the 01's that occur inbetween for example in the second column 01 should be highlighted but not 20:01 or 00126.
$string = preg_replace('/('.$keyword.')/i', "<span style=\"color: $f; background-color: $b;\">$1</span>", $string);
Optionally I think I would also like to highlight the whole line so I need help figuring out how to preg_replace the whole word and then maybe highlight a whole line from 1) 01 1 20080617 20:01 00260 0 the line is terminated with <BR>