> $searchenquiry = "Never cry Wolfe"
> and
> $mydata->ST contains "... Never Cry Wolfe ..."
>
> This code echos:
> <td>".preg_replace ('/('.$searchenquiry.')/i' , "<b>$1</b>",
> $mydata->ST)." </td>
>
> <td>... <b>Never cry Wolfe</b> ...</td>
>
> But I want it to use the original text and echo:
>
> <td>... <b>Never Cry Wolfe</b> ...</td>
I just tried this code:
$searchenquiry = "Never cry Wolfe";
$mydata = "... Never Cry Wolfe ...";
$new = preg_replace ('/('.$searchenquiry.')/i' , "<b>$1</b>", $mydata);
echo "<td>$new </td>";
here was my output:
<td>... <b>Never Cry Wolfe</b> ... </td>
isnt that what you want?
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php