diff options
author | Dries Buytaert <dries@buytaert.net> | 2010-01-07 20:55:49 +0000 |
---|---|---|
committer | Dries Buytaert <dries@buytaert.net> | 2010-01-07 20:55:49 +0000 |
commit | 6dc7e86b805b8d77168e473eeec765313ee3781e (patch) | |
tree | 0f520aa2f56733d52db201c3441d20f1252e920c | |
parent | 605d450aca348a3d9a9ce0fb7072511483c693e1 (diff) | |
download | brdo-6dc7e86b805b8d77168e473eeec765313ee3781e.tar.gz brdo-6dc7e86b805b8d77168e473eeec765313ee3781e.tar.bz2 |
- Patch #677662 by heyrocker: fixed in several hook_token() implementations so that language options get set properly.
-rw-r--r-- | modules/comment/comment.tokens.inc | 5 | ||||
-rw-r--r-- | modules/node/node.tokens.inc | 4 | ||||
-rw-r--r-- | modules/poll/poll.tokens.inc | 1 |
3 files changed, 5 insertions, 5 deletions
diff --git a/modules/comment/comment.tokens.inc b/modules/comment/comment.tokens.inc index e075c1296..60db70fab 100644 --- a/modules/comment/comment.tokens.inc +++ b/modules/comment/comment.tokens.inc @@ -180,11 +180,12 @@ function comment_tokens($type, $tokens, array $data = array(), array $options = // Comment related URLs. case 'url': - $replacements[$original] = url('comment/' . $comment->cid, array('absolute' => TRUE, 'fragment' => 'comment-' . $comment->cid)); + $url_options['fragment'] = 'comment-' . $comment->cid; + $replacements[$original] = url('comment/' . $comment->cid, $url_options); break; case 'edit-url': - $replacements[$original] = url('comment/' . $comment->cid . '/edit', array('absolute' => TRUE)); + $replacements[$original] = url('comment/' . $comment->cid . '/edit', $url_options); break; // Default values for the chained tokens handled below. diff --git a/modules/node/node.tokens.inc b/modules/node/node.tokens.inc index 06a46310a..a62190dbd 100644 --- a/modules/node/node.tokens.inc +++ b/modules/node/node.tokens.inc @@ -163,11 +163,11 @@ function node_tokens($type, $tokens, array $data = array(), array $options = arr break; case 'url': - $replacements[$original] = url('node/' . $node->nid, array('absolute' => TRUE)); + $replacements[$original] = url('node/' . $node->nid, $url_options); break; case 'edit-url': - $replacements[$original] = url('node/' . $node->nid . '/edit', array('absolute' => TRUE)); + $replacements[$original] = url('node/' . $node->nid . '/edit', $url_options); break; // Default values for the chained tokens handled below. diff --git a/modules/poll/poll.tokens.inc b/modules/poll/poll.tokens.inc index 37d82ab0c..6affdb74a 100644 --- a/modules/poll/poll.tokens.inc +++ b/modules/poll/poll.tokens.inc @@ -40,7 +40,6 @@ function poll_token_info() { * Implements hook_tokens(). */ function poll_tokens($type, $tokens, array $data = array(), array $options = array()) { - $url_options = array('absolute' => TRUE); $sanitize = !empty($options['sanitize']); $replacements = array(); |