1
0
mirror of https://github.com/monstra-cms/monstra.git synced 2025-08-13 00:24:27 +02:00

Frontend Improvements

This commit is contained in:
Awilum
2013-12-14 00:40:55 +02:00
parent 798f558558
commit 9b4ff3e2e3
11 changed files with 346 additions and 221 deletions

View File

@@ -1,16 +1,25 @@
<h2><?php echo __('Pages', 'pages'); ?></h2>
<br />
<div>
<div class="pull-left">
<h2><?php echo __('Pages', 'pages'); ?></h2>
</div>
<div class="pull-right">
<br>
<?php
echo (
Html::anchor(__('Create New Page', 'pages'), 'index.php?id=pages&action=add_page', array('title' => __('Create New Page', 'pages'), 'class' => 'btn btn-primary')). Html::nbsp(3).
Html::anchor(__('Edit 404 Page', 'pages'), 'index.php?id=pages&action=edit_page&name=error404', array('title' => __('Create New Page', 'pages'), 'class' => 'btn btn-default'))
);
?>
</div>
<div class="clearfix"></div>
</div>
<br>
<?php if (Notification::get('success')) Alert::success(Notification::get('success')); ?>
<?php
echo (
Html::anchor(__('Create New Page', 'pages'), 'index.php?id=pages&action=add_page', array('title' => __('Create New Page', 'pages'), 'class' => 'btn btn-small')). Html::nbsp(3).
Html::anchor(__('Edit 404 Page', 'pages'), 'index.php?id=pages&action=edit_page&name=error404', array('title' => __('Create New Page', 'pages'), 'class' => 'btn btn-small'))
);
?>
<br /><br />
<br>
<table class="table table-bordered">
<thead>
@@ -69,35 +78,33 @@
</td>
<td>
<div class="pull-right">
<div class="btn-group">
<?php echo Html::anchor(__('Edit', 'pages'), 'index.php?id=pages&action=edit_page&name='.$page['slug'], array('class' => 'btn btn-small')); ?>
<a class="btn dropdown-toggle btn-small" data-toggle="dropdown" href="#" style="font-family:arial;"><span class="caret"></span></a>
<ul class="dropdown-menu">
<?php echo Html::anchor(__('Edit', 'pages'), 'index.php?id=pages&action=edit_page&name='.$page['slug'], array('class' => 'btn btn-primary')); ?>
<button type="button" class="btn btn-primary dropdown-toggle" data-toggle="dropdown">
<span class="caret"></span>
<span class="sr-only">Toggle Dropdown</span>
</button>
<ul class="dropdown-menu" role="menu">
<?php if ($page['parent'] == '') { ?>
<li><a href="index.php?id=pages&action=add_page&parent_page=<?php echo $page['slug']; ?>" title="<?php echo __('Create New Page', 'pages'); ?>"><?php echo __('Add', 'pages'); ?></a></li>
<?php } ?>
<li><?php echo Html::anchor(__('Clone', 'pages'), 'index.php?id=pages&action=clone_page&name='.$page['slug'].'&token='.Security::token(), array('title' => __('Clone', 'pages'))); ?></li>
<li class="divider"></li>
<li class="dropdown-submenu pull-left">
<a href=""><?php echo __('Status', 'pages'); ?></a>
<ul class="dropdown-menu">
<li><a href="index.php?id=pages&action=update_status&slug=<?php echo $page['slug']; ?>&status=published&token=<?php echo Security::token(); ?>"><?php echo __('Published', 'pages'); ?> <?php if ($page['_status'] == 'published') { ?><i class="icon-ok"></i><?php } ?></a></li>
<li><a href="index.php?id=pages&action=update_status&slug=<?php echo $page['slug']; ?>&status=draft&token=<?php echo Security::token(); ?>"><?php echo __('Draft', 'pages'); ?> <?php if ($page['_status'] == 'draft') { ?><i class="icon-ok"></i><?php } ?></a></li>
</ul>
</li>
<li class="dropdown-submenu pull-left">
<a href=""><?php echo __('Access', 'pages'); ?></a>
<ul class="dropdown-menu">
<li><a href="index.php?id=pages&action=update_access&slug=<?php echo $page['slug']; ?>&access=public&token=<?php echo Security::token(); ?>"><?php echo __('Public', 'pages'); ?> <?php if ($page['_access'] == 'public') { ?><i class="icon-ok"></i><?php } ?></a></li>
<li><a href="index.php?id=pages&action=update_access&slug=<?php echo $page['slug']; ?>&access=registered&token=<?php echo Security::token(); ?>"><?php echo __('Registered', 'pages'); ?> <?php if ($page['_access'] == 'registered') { ?><i class="icon-ok"></i><?php } ?></a></li>
</ul>
</li>
</ul>
<?php echo Html::anchor(__('Delete', 'pages'),
'index.php?id=pages&action=delete_page&name='.$page['slug'].'&token='.Security::token(),
array('class' => 'btn btn-actions btn-small btn-actions-default', 'onclick' => "return confirmDelete('".__("Delete page: :page", 'pages', array(':page' => Html::toText($page['title'])))."')"));
?>
<li class="dropdown-header"><?php echo __('Status', 'pages'); ?></li>
<li><a href="index.php?id=pages&action=update_status&slug=<?php echo $page['slug']; ?>&status=published&token=<?php echo Security::token(); ?>"><?php echo __('Published', 'pages'); ?> <?php if ($page['_status'] == 'published') { ?><i class="glyphicon glyphicon-ok"></i><?php } ?></a></li>
<li><a href="index.php?id=pages&action=update_status&slug=<?php echo $page['slug']; ?>&status=draft&token=<?php echo Security::token(); ?>"><?php echo __('Draft', 'pages'); ?> <?php if ($page['_status'] == 'draft') { ?><i class="glyphicon glyphicon-ok"></i><?php } ?></a></li>
<li class="dropdown-header"><?php echo __('Access', 'pages'); ?></li>
<li><a href="index.php?id=pages&action=update_access&slug=<?php echo $page['slug']; ?>&access=public&token=<?php echo Security::token(); ?>"><?php echo __('Public', 'pages'); ?> <?php if ($page['_access'] == 'public') { ?><i class="glyphicon glyphicon-ok"></i><?php } ?></a></li>
<li><a href="index.php?id=pages&action=update_access&slug=<?php echo $page['slug']; ?>&access=registered&token=<?php echo Security::token(); ?>"><?php echo __('Registered', 'pages'); ?> <?php if ($page['_access'] == 'registered') { ?><i class="glyphicon glyphicon-ok"></i><?php } ?></a></li>
</ul>
</div>
<?php echo Html::anchor(__('Delete', 'pages'),
'index.php?id=pages&action=delete_page&name='.$page['slug'].'&token='.Security::token(),
array('class' => 'btn btn-danger btn-actions btn-actions-default', 'onclick' => "return confirmDelete('".__("Delete page: :page", 'pages', array(':page' => Html::toText($page['title'])))."')"));
?>
</div>
</td>
</tr>