1
0
mirror of https://github.com/e107inc/e107.git synced 2025-08-18 20:31:41 +02:00

Fixed Meta-Tag overwrite issue. Changed eResponse to singleton. May correct problems with Facebook app-id and custom og:image. Pages possibly affected: front-page (index.php) and news, custom-page and user pages.

This commit is contained in:
Cameron
2017-06-05 17:49:49 -07:00
parent dce42f3e31
commit caea384495
4 changed files with 22 additions and 9 deletions

View File

@@ -163,7 +163,8 @@ if ($e_headers && is_array($e_headers))
}
unset($e_headers);
echo e107::getUrl()->response()->renderMeta()."\n"; // render all the e107::meta() entries.
// echo e107::getUrl()->response()->renderMeta()."\n"; // render all the e107::meta() entries.
echo e107::getSingleton('eResponse')->renderMeta()."\n";
echo "<title>".(defined('e_PAGETITLE') ? e_PAGETITLE.' - ' : (defined('PAGE_NAME') ? PAGE_NAME.' - ' : "")).SITENAME."</title>\n\n";
@@ -490,8 +491,15 @@ function render_meta($type)
}
// legay meta-tag checks.
/*
$isKeywords = e107::getUrl()->response()->getMetaKeywords();
$isDescription = e107::getUrl()->response()->getMetaDescription();
*/
$isKeywords = e107::getSingleton('eResponse')->getMetaKeywords();
$isDescription = e107::getSingleton('eResponse')->getMetaDescription();
if(empty($isKeywords))
{
echo (defined("META_KEYWORDS")) ? "\n<meta name=\"keywords\" content=\"".$key_merge.META_KEYWORDS."\" />\n" : render_meta('keywords');