On 1/23/06, Richard K Miller <[EMAIL PROTECTED]> wrote:

> function link_the_links($s) {
>         return preg_replace('@(http://[^\s]+)@sm', '<a href="$1">$1</a>', $s);
> }

> I've got to somehow ignore the trailing period if it is present.

if ($s[strlen($s)-1] == '.'){
  $s = substr($s, 0, -1);
}

-ahmed

Reply via email to