blob: 2476353216215e50ea0b43f2ac8b076bfd425e7a (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
|
<?php
if ($app->exist($_GET['id'])) {
$art = $app->get($_GET['id']);
if (isset($_GET['edit']) and $_GET['edit'] == 1 and $app->session() >= $app::EDITOR) {
echo '<section class=edit>';
$aff->edit($art, $app, $app->getlister(['id', 'title']), $config->fontsize(), $app->getlistermedia($app::MEDIA_DIR, 'image'));
$aff->aside($app);
echo '</section>';
} else {
echo '<section class="lecture">';
$art->autotaglistupdate($app->taglist($app->getlister(['id', 'title', 'description', 'tag']), $art->autotaglist()));
$aff->lecture($art, $app);
echo '</section>';
}
} else {
echo '<span class="alert">This article does not exist yet</span>';
if ($app->session() >= $app::EDITOR) {
echo '<form action="?id=' . $_GET['id'] . '&edit=1" method="post"><input type="hidden" name="action" value="new"><input type="submit" value="Create"></form>';
}
}
?>
|