Hello Guys,
Need a small help, as this is complex for me. With PHP 5.4, our server throws "Deprecated: Function eregi_replace() is deprecated" for a file and need you experts help to convert below 3 lines and replace it with preg_replace function. Can any one help with new lines of below code :
$body_html = eregi_replace('(((f|ht){1}tp://)[-a-zA-Z0-9@:%_\+.~#?&//=]+)', '<a href="\\1">\\1</a>', $body_html);
$body_html = eregi_replace('([[:space:]()[{}])(www.[-a-zA-Z0-9@:%_\+.~#?&//=]+)', '\\1<a href="http://\\2">\\2</a>', $body_html);
$body_html = eregi_replace('([_\.0-9a-z-]+@([0-9a-z][0-9a-z-]+\.)+[a-z]{2,3})', '<a href="mailto:\\1">\\1</a>', $body_html);
Thank you & Appreciate it.