diff --git a/core/modules/node/node.module b/core/modules/node/node.module index 349cde6e6ca..4dc5934e382 100644 --- a/core/modules/node/node.module +++ b/core/modules/node/node.module @@ -1490,7 +1490,10 @@ function template_preprocess_node(&$variables) { $node = $variables['node']; $variables['date'] = format_date($node->created); - $variables['name'] = theme('username', array('account' => $node)); + $variables['name'] = theme('username', array( + 'account' => $node, + 'link_attributes' => array('rel' => 'author'), + )); $uri = entity_uri('node', $node); $variables['node_url'] = url($uri['path'], $uri['options']); diff --git a/core/modules/user/user.module b/core/modules/user/user.module index eb2f521c417..8e917aabc85 100644 --- a/core/modules/user/user.module +++ b/core/modules/user/user.module @@ -1457,20 +1457,19 @@ function template_preprocess_username(&$variables) { $name = drupal_substr($name, 0, 15) . '...'; } $variables['name'] = check_plain($name); - $variables['profile_access'] = user_access('access user profiles'); - $variables['link_attributes'] = array(); + // Populate link path and attributes if appropriate. if ($variables['uid'] && $variables['profile_access']) { // We are linking to a local user. - $variables['link_attributes'] = array('title' => t('View user profile.')); + $variables['link_attributes']['title'] = t('View user profile.'); $variables['link_path'] = 'user/' . $variables['uid']; } elseif (!empty($account->homepage)) { // Like the 'class' attribute, the 'rel' attribute can hold a // space-separated set of values, so initialize it as an array to make it // easier for other preprocess functions to append to it. - $variables['link_attributes'] = array('rel' => array('nofollow')); + $variables['link_attributes']['rel'] = 'nofollow'; $variables['link_path'] = $account->homepage; $variables['homepage'] = $account->homepage; } diff --git a/sites/default/default.settings.php b/sites/default/default.settings.php old mode 100644 new mode 100755