summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAngie Byron <webchick@24967.no-reply.drupal.org>2010-11-22 08:01:24 +0000
committerAngie Byron <webchick@24967.no-reply.drupal.org>2010-11-22 08:01:24 +0000
commitb7bcc866cc41c907ddf53bded4fa1c7f31c38b30 (patch)
tree726686d42d214fa5e54e9dbcf4608901da07982a
parentf9c40ea5a0dfdf289a87d68235bb709017ce339b (diff)
downloadbrdo-b7bcc866cc41c907ddf53bded4fa1c7f31c38b30.tar.gz
brdo-b7bcc866cc41c907ddf53bded4fa1c7f31c38b30.tar.bz2
#49428 by levavie, mgifford, joachim, et al: Include node title in 'Read more' link for better accessibility and SEO
-rw-r--r--modules/node/node.module6
1 files changed, 4 insertions, 2 deletions
diff --git a/modules/node/node.module b/modules/node/node.module
index bfad1a07a..ae193a68d 100644
--- a/modules/node/node.module
+++ b/modules/node/node.module
@@ -1349,10 +1349,12 @@ function node_build_content($node, $view_mode = 'full', $langcode = NULL) {
'#attributes' => array('class' => array('links', 'inline')),
);
if ($view_mode == 'teaser') {
+ $node_title_stripped = strip_tags($node->title);
$links['node-readmore'] = array(
- 'title' => t('Read more'),
+ 'title' => t('Read more<span class="element-invisible"> about @title</span>', array('@title' => $node_title_stripped)),
'href' => 'node/' . $node->nid,
- 'attributes' => array('rel' => 'tag', 'title' => strip_tags($node->title))
+ 'html' => TRUE,
+ 'attributes' => array('rel' => 'tag', 'title' => $node_title_stripped),
);
}
$node->content['links']['node'] = array(