Solved bug 1491 in all the "linking" filters.

(http://moodle.org/bugs/bug.php?op=show&bugid=1491)
Bugfix 001
This commit is contained in:
stronk7 2004-05-30 01:00:16 +00:00
parent 0ae7e6f40e
commit 2ed07cc70a
3 changed files with 4 additions and 4 deletions

View File

@ -2,7 +2,7 @@
//This function provides automatic linking to
//activities when its name (title) is found inside every Moodle text
//It's based in the glosssary filter by Williams Castillo
//Modifications by stronk7. Enjoy! :-)
//Modifications by stronk7.
$textfilter_function='activitynames_filter';
@ -84,7 +84,7 @@
//Now avoid searching inside links
$links = array();
preg_match_all('/<A (.+?)>(.+?)<\/A>/is',$text,$list_of_links);
preg_match_all('/<A[\s](.+?)>(.+?)<\/A>/is',$text,$list_of_links);
foreach (array_unique($list_of_links[0]) as $key=>$value) {
$links['<@'.$key.'@>'] = $value;
}

View File

@ -164,7 +164,7 @@
//Now avoid searching inside links
$links = array();
preg_match_all('/<A (.+?)>(.+?)<\/A>/is',$text,$list_of_links);
preg_match_all('/<A[\s](.+?)>(.+?)<\/A>/is',$text,$list_of_links);
foreach (array_unique($list_of_links[0]) as $key=>$value) {
$links['<@'.$key.'@>'] = $value;
}

View File

@ -102,7 +102,7 @@
//Now avoid searching inside links
$links = array();
preg_match_all('/<A (.+?)>(.+?)<\/A>/is',$text,$list_of_links);
preg_match_all('/<A[\s](.+?)>(.+?)<\/A>/is',$text,$list_of_links);
foreach (array_unique($list_of_links[0]) as $key=>$value) {
$links['<@'.$key.'@>'] = $value;
}