Posted: Fri Aug 13, 2004 5:39 am
hmm, lets try the simpler approach:now, it kinda looks like we'll need a stripslashes in there, but not too sure..
Code: Select all
<?php
if(preg_match_all['#\['.'php](.*?)\[/'.'php]#is', $r['eksart'],$matches))
{
foreach($matches[0] as $k => $str)
$r['eksart'] = str_replace($str, '<b>PHP:</b><br><table width="100%" border="0" cellspacing="0" cellpadding="0" style="background-color: #FAFAFA; border: 1px solid #D1D7DC;">
<tr>
<td style="padding-left: 10px; padding-right: 10px; padding-top: 10px; padding-bottom: 10px;">' . highlight_string($matches[1][$k],true) . '</td>
</tr>
</table>');
}
?>