From: Coleman Watts Date: Sat, 31 Jan 2015 03:06:45 +0000 (-0500) Subject: CRM-15898 - Use simpler version of title as global X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=46d70d2840764c5a5eab48c6eb381c0ce57cebe1;p=civicrm-core.git CRM-15898 - Use simpler version of title as global ---------------------------------------- * CRM-15898: Set in wordpress header https://issues.civicrm.org/jira/browse/CRM-15898 --- diff --git a/CRM/Utils/System/WordPress.php b/CRM/Utils/System/WordPress.php index 0b3c3eefd2..cc9865e2bb 100644 --- a/CRM/Utils/System/WordPress.php +++ b/CRM/Utils/System/WordPress.php @@ -69,8 +69,9 @@ class CRM_Utils_System_WordPress extends CRM_Utils_System_Base { // do we have functionality provided by plugin version 4.6+ present? if (method_exists($civi, 'civicrm_context_get')) { + // FIXME: Why is this global? global $civicrm_wp_title; - $civicrm_wp_title = $pageTitle; + $civicrm_wp_title = $title; // yes, set page title, depending on context $context = civi_wp()->civicrm_context_get(); @@ -86,7 +87,7 @@ class CRM_Utils_System_WordPress extends CRM_Utils_System_Base { // legacy pre-4.6 behaviour global $civicrm_wp_title; - $civicrm_wp_title = $pageTitle; + $civicrm_wp_title = $title; $template = CRM_Core_Smarty::singleton(); $template->assign('pageTitle', $pageTitle);