<?PHP

if($this->templates->Numrows > 0){

	$row = $this->templates->Each();
	$link = $this->Link('?page=page&show_page='.$row['name'].'&id='.$row['menu_id'], array('id'));

	?>
	<div class="tekst">
	<h2><?
		//preg_replace_callback('/\[PLUGIN=(.*)\]/', function( $matches ) {require $this->callPlugin(html_entity_decode($matches[1]));}, $row['content']);
		require $this->savePluginFile($row['id'], $row['content']);
	?></h2>
	</div>
	<?

	if($this->permissions->Numrows > 0){

		echo '<a href="'._RootUrl.'/admin?model=content&page=edit&id='.$row['related_id'].'&template_id='.$row['template_id'].'" class="_blank" style="display:block;margin:10px 0px 10px 0px;text-transform:uppercase;font-size:15px;">['.$this->Language('Edit').']</a>';
	}
}

?>