aboutsummaryrefslogtreecommitdiff
path: root/views/default/output
diff options
context:
space:
mode:
authorcash <cash@36083f99-b078-4883-b0ff-0f9b5a30f544>2010-11-20 21:46:27 +0000
committercash <cash@36083f99-b078-4883-b0ff-0f9b5a30f544>2010-11-20 21:46:27 +0000
commit96f880d1e535aaf47d0c67cfe3da8fca638dc00d (patch)
tree30dac1adcc40800a7f54dd14ea03b04a3bfd84bd /views/default/output
parent39c9047b5152128e5bbfe960c36dd2b860f2d3d0 (diff)
downloadelgg-96f880d1e535aaf47d0c67cfe3da8fca638dc00d.tar.gz
elgg-96f880d1e535aaf47d0c67cfe3da8fca638dc00d.tar.bz2
Refs #2143 fix for commit [7354] as ampersands were being doubly encoded
git-svn-id: http://code.elgg.org/elgg/trunk@7391 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'views/default/output')
-rw-r--r--views/default/output/url.php9
1 files changed, 5 insertions, 4 deletions
diff --git a/views/default/output/url.php b/views/default/output/url.php
index 6e77a1984..8ea84d3d6 100644
--- a/views/default/output/url.php
+++ b/views/default/output/url.php
@@ -7,6 +7,7 @@
* @subpackage Core
*
* @uses string $vars['text'] The string between the <a></a> tags.
+ * @uses string $vars['href'] The unencoded url string
* @uses bool $vars['encode_text'] Run $vars['text'] through htmlspecialchars()?
* @uses bool $vars['is_action'] Is this a link to an action?
*
@@ -18,7 +19,7 @@ if (!$url and isset($vars['value'])) {
unset($vars['value']);
}
-if (!empty($url)) {
+if (!empty($url)) {
if (isset($vars['text'])) {
if (isset($vars['encode_text']) && $vars['encode_text']) {
$text = htmlspecialchars($vars['text'], ENT_QUOTES, 'UTF-8');
@@ -36,12 +37,12 @@ if (!empty($url)) {
$url = elgg_normalize_url($url);
if (isset($vars['is_action'])) {
- $url = elgg_add_action_tokens_to_url($url);
+ $url = elgg_add_action_tokens_to_url($url, FALSE);
unset($vars['is_action']);
}
$vars['href'] = $url;
-
+
$attributes = elgg_format_attributes($vars);
- echo "<a $attributes>$text</a>";
+ echo "<a $attributes>$text</a>";
} \ No newline at end of file