|Provided by bundle||built-in|
This processor is used to insert HTML tags (
meta) that are specified by
extensions or via special node meta information keys before the end of the HTML head section.
This content processor should be used on template files since its output is only useful in the head section of an HTML file. And it should be the last content processor in the processing pipeline because otherwise not all needed information may be set!
Also note that there is no need for a special markup since the HTML head end tag is unique in a HTML
document and therefore the insertion place can be found automatically. This also means that nothing
is done by this processor if the closing
</head> HTML tag is left out!
Handled HTML Tags
The tags that are inserted can be specified in various ways:
metatags can be set during the rendering of a page file by any extension on a page-per-page basis.
This is accomplished by using the
context.html_headobject (an instance of Webgen::Context::HtmlHead::Proxy). It provides utiltity methods for all possibilities.
Arbitrary meta tags can be inserted on a page-per-page basis by the user by setting the meta meta information on a page file. If you need to use the
propertykey instead of the
namekey (e.g. for specifying OpenGraph properties), you need to use the meta_property meta information.
Arbitrary link tags can also be inserted by setting the link meta information. This allows one, for example, to specify which page file logically follows or precedes a given page file.
The processor also automatically inserts
link tags to translations of the rendered page file.
Developers wanting to use the functionality of this content processor should have a look at the API documentation of Webgen::ContentProcessor::HtmlHead.