]> git.mjollnir.org Git - moodle.git/commitdiff
Fixed that damn www linking problem with words like wwwroot :-)
authormoodler <moodler>
Thu, 2 Jan 2003 14:54:33 +0000 (14:54 +0000)
committermoodler <moodler>
Thu, 2 Jan 2003 14:54:33 +0000 (14:54 +0000)
lib/weblib.php

index dc7655adcaec238fe671c2a033e71ac1cce6fdc6..1766af06a3d7c5fd7388d6aa98fc642527b1739d 100644 (file)
@@ -506,7 +506,7 @@ function text_to_html($text, $smiley=true, $para=true) {
                           "\\1<A HREF=\"\\2://\\3\\4\" TARGET=\"newpage\">\\2://\\3\\4</A>", $text);
 
 /// eg www.moodle.com
-    $text = eregi_replace("([[:space:]])www.([^[:space:]]*)([[:alnum:]#?/&=])", 
+    $text = eregi_replace("([[:space:]])www\.([^[:space:]]*)([[:alnum:]#?/&=])", 
                           "\\1<A HREF=\"http://www.\\2\\3\" TARGET=\"newpage\">www.\\2\\3</A>", $text);
 
 /// Make returns into HTML newlines.