* @license PHP License * @package WB * @subpackage content */ /** * Load base class */ WBClass::load( 'WBContent', 'WBContent_SEO' ); /** * Content component: SEO * * @version 1.0.0 * @package WB * @subpackage content */ class WBContent_SEO_Manifest extends WBContent_SEO { /** * run * * run component * * @see sendAndExit() * @return array parameter list */ public function run() { $conf = WBClass::create('WBConfig'); $icons = [ [ "src" => WBString::replaceSuperPlaceholders("[[SELF]]favicon-192.png"), "type" => "image/png", "sizes" => "192x192" ], [ "src" => WBString::replaceSuperPlaceholders("[[SELF]]favicon-512.png"), "type" => "image/png", "sizes" => "512x512" ] ]; $manifest = [ "icons" => $icons ]; $manifestJSON = json_encode($manifest); $this->res->add($manifestJSON); $this->sendAndExit('application/manifest+json'); } }