add_hook('render_page', array($this, 'add_manifest')); } function add_manifest($p) { $manifest_url = $this->url('manifest.json'); $p['content'] = preg_replace('//', '' . "\n" . ' ', $p['content'], 1); return $p; } }