developmentseed / developmentseed/FeatureServer

SEO issue: titles

Offen
#12 0 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen
Vorherrschende Sprache
PHP
Sterne
46
Forks
14
PR-Merge-Kennzahlen
Keine gemergten PRs in 30 T.

Beschreibung

Currently FServer causes the main project page and the associated "all releases" page to have an identical title, which gets reported in Google webmasters tools.

A possible quick fix is to modify the head title when the page template is the one for releases, indicating that this is the releases page:

/**

* Implements hook_preprocess_page().
*/
function fserver_preprocess_page(&$vars) {
if (in_array('page-node-releases', $vars['template_files'])) {
list($title, $site) = explode(' | ', $vars['head_title']);
$vars['head_title'] = t('@title: All releases | @site', array(
'@title' => $title,
'@site' => $site,
));
}
}

Beitragsleitfaden

Für dieses Repository ist kein Beitragsleitfaden indexiert

Bewertung

Dieses Issue wurde noch nicht bewertet.

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.