X-Git-Url: http://git.polytechnique.org/?a=blobdiff_plain;f=plugins%2FHtmlHead.php;fp=plugins%2FHtmlHead.php;h=a1be65c6137133d1eea7d518548c3659f2b0457f;hb=6855525e48fad5de270500a5445c4f4ff85d8bda;hp=0000000000000000000000000000000000000000;hpb=e69709aa8ee6108a1197e46b45367ba8dab55a52;p=diogenes.git diff --git a/plugins/HtmlHead.php b/plugins/HtmlHead.php new file mode 100644 index 0000000..a1be65c --- /dev/null +++ b/plugins/HtmlHead.php @@ -0,0 +1,54 @@ + block. + */ +class HtmlHead extends Diogenes_Plugin_Filter +{ + /** Plugin name */ + var $name = "HtmlHead"; + + /** Plugin description */ + var $description = "This plugin allows you to add entries to a page's <head> block."; + + /** Plugin parameters */ + var $params = array('contents' => ''); + + /** Apply filtering to the input and return an output. + * + * @param $input + */ + function filter($input) + { + global $page; + + if ($this->params['contents']) + { + array_push($page->head, $this->params['contents']); + } + + return $input; + } + +} +?>