From 32ba2f0dd4ad1cd6947e601369e9dabd66f2c7e8 Mon Sep 17 00:00:00 2001 From: jamiesensei Date: Fri, 2 May 2008 16:11:30 +0000 Subject: [PATCH] MDL-14663 "link_to_popup_window displays 'Click here....' as the link text if you pass in 0 as the link text." Also fixing the problem in link_to_popup_window function. Test for null instead of empty. --- lib/weblib.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/weblib.php b/lib/weblib.php index 09f9b178ee4b7..39f9a34d367ad 100644 --- a/lib/weblib.php +++ b/lib/weblib.php @@ -675,7 +675,7 @@ function element_to_popup_window ($type=null, $url=null, $name=null, $linkname=n } // get some default string, using the localized version of legacy defaults - if (!$linkname) { + if (is_null($linkname) || $linkname === '') { $linkname = get_string('clickhere'); } if (!$title) {