make page feature image meta image

This commit is contained in:
Ro 2021-04-27 20:09:18 +00:00
parent 1f46eeffa0
commit 89f84499b2

View file

@ -23,6 +23,7 @@ class Render
"description" => $settings["global"]["descriptions"],
"image" =>
$settings["global"]["base_url"] . $settings["global"]["background"],
"baseURL" => $settings["global"]["base_url"],
];
//copy current theme assets to public
if (is_file("../public/assets/css/base.css")) {
@ -120,6 +121,12 @@ class Render
//$cleaned = preg_replace('/(?:\r\n|[\r\n]){2,}/', "\n\n", $cleaned);
//$cleaned = html_entity_decode($cleaned, ENT_QUOTES, "UTF-8");
//if page feature isn't empty, replace page info meta image
if ($page["feature"] != "" || $page["feature"] != null) {
$this->pageInfo["image"] =
$this->pageInfo["baseURL"] . $page["feature"];
}
if ($page["layout"] == "index") {
$template = $this->theme . "/index.twig";
$location = "../public/index.html";