dj_mix_hosting_software/includes/header-meta.php

20 lines
581 B
PHP

<?php
require_once 'includes/globals.php';
require_once 'vendor/autoload.php';
use DJMixHosting\HeaderMeta;
$mixPages = ["/mix/", "/mix.php"];
$page = $_SERVER['SCRIPT_NAME'];
// the $mixPages has a list of pages, but the request or script name might be /mix/content or /mix.php?mix=content...
// so we need to check if the script name contains any of the pages in the $mixPages array
if (isset($mix)) {
if (str_contains($page, $mixPages[0])) {
$headerMeta = new HeaderMeta($mix, $config);
$meta = $headerMeta->mixMetaOutput();
echo $meta;
}
}