aboutsummaryrefslogtreecommitdiff
path: root/app/view/templates
diff options
context:
space:
mode:
authorvincent-peugnet <v.peugnet@free.fr>2018-12-05 18:37:30 +0100
committervincent-peugnet <v.peugnet@free.fr>2018-12-05 18:37:30 +0100
commit7fb607b48c181512b31f52a7ef7e302f331ec18d (patch)
treec4d89cba3c0d01679ed1455e0d7c39fa2fdb824c /app/view/templates
parentad3aed389f2e0d69802641f5a5b7c6add73f1ce5 (diff)
downloadwcms-7fb607b48c181512b31f52a7ef7e302f331ec18d.tar.gz
wcms-7fb607b48c181512b31f52a7ef7e302f331ec18d.zip
mediastyle
Diffstat (limited to 'app/view/templates')
-rw-r--r--app/view/templates/admin.php2
-rw-r--r--app/view/templates/backtopbar.php21
-rw-r--r--app/view/templates/font.php2
-rw-r--r--app/view/templates/home.php2
-rw-r--r--app/view/templates/info.php25
-rw-r--r--app/view/templates/media.php67
6 files changed, 109 insertions, 10 deletions
diff --git a/app/view/templates/admin.php b/app/view/templates/admin.php
index 5edf262..6e8e0ab 100644
--- a/app/view/templates/admin.php
+++ b/app/view/templates/admin.php
@@ -5,7 +5,7 @@
<body>
- <?php $this->insert('backtopbar', ['user' => $user]) ?>
+ <?php $this->insert('backtopbar', ['user' => $user, 'tab' => 'admin']) ?>
<section class="admin">
diff --git a/app/view/templates/backtopbar.php b/app/view/templates/backtopbar.php
index a06c304..d769993 100644
--- a/app/view/templates/backtopbar.php
+++ b/app/view/templates/backtopbar.php
@@ -1,5 +1,13 @@
<div id="topbar">
+<span id="search">
+<form action="<?= $this->url('search') ?>" method="post">
+<input type="text" name="id" id="id" placeholder="page id" required>
+<input type="submit" value="go">
+</form>
+</span>
+
+
<span id="user">
<?php if($user->isvisitor()) { ?>
@@ -14,7 +22,7 @@
<?php } else { ?>
<span>
-User level : <?= $user->level() ?>
+<?= $user->level() ?>
</span>
@@ -33,17 +41,18 @@ User level : <?= $user->level() ?>
<?php if($user->iseditor()) { ?>
-<span>
-<a href="<?= $this->url('home') ?>">home</a>
+<span id="menu">
+<a href="<?= $this->url('home') ?>" <?= $tab == 'home' ? 'class="actualpage"' : '' ?>>home</a>
+<a href="<?= $this->url('media') ?>" <?= $tab == 'media' ? 'class="actualpage"' : '' ?>>media</a>
+<a href="<?= $this->url('font') ?>" <?= $tab == 'font' ? 'class="actualpage"' : '' ?>>font</a>
<?php
if($user->isadmin()) {
?>
-<a href="<?= $this->url('font') ?>">font</a>
-<a href="<?= $this->url('admin') ?>">admin</a>
+<a href="<?= $this->url('admin') ?>" <?= $tab == 'admin' ? 'class="actualpage"' : '' ?>>admin</a>
<?php
}
?>
-| <i><a href="https://github.com/vincent-peugnet/wcms" target="_blank">github↝</a></i>
+<a href="<?= $this->url('info') ?>" <?= $tab == 'info' ? 'class="actualpage"' : '' ?>>info</a>
</span>
diff --git a/app/view/templates/font.php b/app/view/templates/font.php
index 6e55686..90614a9 100644
--- a/app/view/templates/font.php
+++ b/app/view/templates/font.php
@@ -5,7 +5,7 @@
<body>
- <?php $this->insert('backtopbar', ['user' => $user]) ?>
+ <?php $this->insert('backtopbar', ['user' => $user, 'tab' => 'font']) ?>
<section class="font">
diff --git a/app/view/templates/home.php b/app/view/templates/home.php
index a83361d..87cdb8d 100644
--- a/app/view/templates/home.php
+++ b/app/view/templates/home.php
@@ -8,7 +8,7 @@
<body>
- <?php $this->insert('backtopbar', ['user' => $user]) ?>
+ <?php $this->insert('backtopbar', ['user' => $user, 'tab' => 'home']) ?>
<?php if($user->iseditor()) { ?>
diff --git a/app/view/templates/info.php b/app/view/templates/info.php
new file mode 100644
index 0000000..231a114
--- /dev/null
+++ b/app/view/templates/info.php
@@ -0,0 +1,25 @@
+<?php $this->layout('layout', ['title' => 'info', 'css' => $css . 'home.css']) ?>
+
+
+<?php $this->start('page') ?>
+
+<body>
+
+ <?php $this->insert('backtopbar', ['user' => $user, 'tab' => 'info']) ?>
+
+
+<section class="info">
+
+<h1>Info</h1>
+
+<a href="https://github.com/vincent-peugnet/wcms" target="_blank">πŸ±β€πŸ‘€ Github</a>
+
+<a href="#">πŸ“• Manual</a>
+<a href="#">🌡 Website</a>
+
+<h2>About</h2>
+
+</section>
+</body>
+
+<?php $this->stop('page') ?> \ No newline at end of file
diff --git a/app/view/templates/media.php b/app/view/templates/media.php
index 31e3ad0..043000d 100644
--- a/app/view/templates/media.php
+++ b/app/view/templates/media.php
@@ -1 +1,66 @@
-<?php $this->layout('layout', ['title' => 'Media']) ?>
+<?php $this->layout('layout', ['title' => 'media', 'css' => $css . 'home.css']) ?>
+
+
+<?php $this->start('page') ?>
+
+<body>
+
+ <?php $this->insert('backtopbar', ['user' => $user, 'tab' => 'media']) ?>
+
+
+<section class="media">
+
+<h1>Media</h1>
+
+<table id="medialist">
+<tr><th>id</th><th>extension</th><th>path</th><th>type</th><th>size</th><th>width</th><th>height</th><th>lengh</th></tr>
+
+<?php
+foreach ($medialist as $media) {
+ ?>
+ <tr>
+ <td><?= $media->id() ?></td>
+ <td><?= $media->extension() ?></td>
+ <td><?= $media->path() ?></td>
+ <td><?= $media->type() ?></td>
+ <td><?= readablesize($media->size()) ?></td>
+ <td><?= $media->width() ?></td>
+ <td><?= $media->height() ?></td>
+ <td><?= $media->length() ?></td>
+ </tr>
+ <?php
+}
+
+
+?>
+
+</table>
+
+<h1>Favicon</h1>
+
+<table id="faviconlist">
+<tr><th>id</th><th>extension</th><th>path</th><th>size</th><th>width</th><th>height</th></tr>
+
+<?php
+foreach ($faviconlist as $favicon) {
+ ?>
+ <tr>
+ <td><?= $favicon->id() ?></td>
+ <td><?= $favicon->extension() ?></td>
+ <td><?= $favicon->path() ?></td>
+ <td><?= readablesize($favicon->size()) ?></td>
+ <td><?= $favicon->width() ?></td>
+ <td><?= $favicon->height() ?></td>
+ </tr>
+ <?php
+}
+
+
+?>
+
+</table>
+
+</section>
+</body>
+
+<?php $this->stop('page') ?> \ No newline at end of file