Commit dcff1a6b authored by Richard Mansfield's avatar Richard Mansfield

Add edit title/edit content tabs for theming

Signed-off-by: default avatarRichard Mansfield <richard.mansfield@catalyst.net.nz>
parent cd0ee8e9
{if $microheaders}{include file="viewmicroheader.tpl"}{else}{include file="header.tpl"}{/if}
{if $edittitleurl && !$microheaders}
<div class="viewtitledesc">
<h1>{$viewtitle}</h1>
<span class="editviewtitle s">
<a title="{str tag=edittitleanddescription section=view}" href="{$edittitleurl}"><img src="{theme_url filename='images/icon-edit.gif'}" alt="{str tag=edittitleanddescription section=view}" /></a>
</span>
</div>
{else}
<h1>{$maintitle}</h1>
{if !$edittitleurl}
<h1>{if !$microheaders}{$viewtitle}{else}{$maintitle}{/if}</h1>
{/if}
{if $edittitleurl}
<ul class="edit-view-tabs">
<li>{$viewtitle}</li>
<li><a class="current-tab" href="{$WWWROOT}view/edit.php?id={$viewid}">{str tag=edittitleanddescription section=view}</a></li>
<li><a class="current-tab" href="{$WWWROOT}view/blocks.php?id={$viewid}">{str tag=editcontent section=view}</a></li>
</ul>
<div class="rel">
{/if}
{if $columns}
......@@ -107,4 +109,7 @@
{if $block.javascript}<script type="text/javascript">{$block.javascript|safe}</script>{/if}
{/if}
{if $edittitleurl}
</div>
{/if}
{if $microheaders}{include file="microfooter.tpl"}{else}{include file="footer.tpl"}{/if}
{include file="header.tpl"}
<ul class="edit-view-tabs">
<li>{$viewtitle}</li>
<li><a class="current-tab" href="{$WWWROOT}view/edit.php?id={$viewid}">{str tag=edittitleanddescription section=view}</a></li>
<li><a href="{$WWWROOT}view/blocks.php?id={$viewid}">{str tag=editcontent section=view}</a></li>
</ul>
<div class="rel">
{$editview|safe}
</div>
{include file="footer.tpl"}
......@@ -182,8 +182,9 @@ function editview_submit(Pieform $form, $values) {
}
$smarty = smarty(array(), array(), array(), array('sidebars' => false));
$smarty->assign('PAGEHEADING', TITLE);
$smarty->assign('editview', $editview);
$smarty->assign('viewid', $view->get('id'));
$smarty->assign('viewtitle', $view->get('title'));
$smarty->display('view/edit.tpl');
?>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment