Header icon indicating copy to clipboard operation
Header copied to clipboard

Add macros for changing meta information from templates

Open romanmatyus opened this issue 12 years ago • 0 comments

Create HeaderCollector as service for collecting information about HTML header.

Add macros {addTitle}, {setTitle}, {addDescription}, {setDescription}, {addKeywords}, {setKeywords}, {setRobots}. This macros save data's to HeaderCollector and HeaderComponent only write data's from HeaderCollector and AssetsCollector.

This allow use this template:

{* set header *}
{addTitle}{$row->title}{/addTitle}
{setDescription}{$row->description}{/setDescription}
{* ... *}

{* and other *}
<h1>{$row->title}</h1>
<div>{$row->description}</div>
{$row->text}

romanmatyus avatar Nov 22 '12 14:11 romanmatyus