<style type=”text/css”>
tr.diff {
background: red;
}
</style>
<?php
$text = “<table border=’1′ width=’200′>
<tr><td> </td></tr>
<tr><td> </td></tr>
<tr><td> </td></tr>
<tr><td> </td></tr>
<tr><td> </td></tr>
<tr><td> </td></tr>
</table>”;
$text = preg_replace(”/((<tr>.*?<\/tr>[^<]*<tr)(>.*?<\/tr>))/s”, “$2 class=’diff’$3″, $text);
echo $text;
?>
Tuesday, April 27, 2010
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment