| Line | |
|---|
| 1 | <?php
|
|---|
| 2 | include('global.php');
|
|---|
| 3 | show_header();
|
|---|
| 4 |
|
|---|
| 5 | echo '<div id="contenu">';
|
|---|
| 6 |
|
|---|
| 7 |
|
|---|
| 8 | if (array_key_exists('spolco',$_GET)) {
|
|---|
| 9 | echo SPOLCO;
|
|---|
| 10 | show_article(1);
|
|---|
| 11 |
|
|---|
| 12 | } else if (array_key_exists('sbor',$_GET)) {
|
|---|
| 13 | echo SBOR;
|
|---|
| 14 | show_article(2);
|
|---|
| 15 |
|
|---|
| 16 | } else if (array_key_exists('rozpis',$_GET)) {
|
|---|
| 17 | echo ROZPIS;
|
|---|
| 18 | show_mass();
|
|---|
| 19 | echo '<br><br>';
|
|---|
| 20 | $files = scandir('mass');
|
|---|
| 21 | for ($i=0;$i<count($files);++$i) {
|
|---|
| 22 | $file = 'mass/'.$files[$i];
|
|---|
| 23 | if (filetype($file) <> 'dir') echo '<a href="?img='.$file.'"><img width="200" src='.$file.' title="'.FILE_SAVED . date ("m d Y H:i:s.", filemtime($file)).'"></a>';
|
|---|
| 24 | }
|
|---|
| 25 | show_article(3);
|
|---|
| 26 |
|
|---|
| 27 | } else if (array_key_exists('Historie',$_GET)) {
|
|---|
| 28 | echo HISTORIE;
|
|---|
| 29 | show_article(4);
|
|---|
| 30 |
|
|---|
| 31 |
|
|---|
| 32 | } else if (array_key_exists('admin',$_GET)) {
|
|---|
| 33 | echo ADMIN;
|
|---|
| 34 | if (array_key_exists('pass',$_POST) ) {
|
|---|
| 35 | if ($_POST['pass'] == $Config['webpass']) {
|
|---|
| 36 | $_SESSION['pass'] = $_POST['pass'];
|
|---|
| 37 | } else {
|
|---|
| 38 | echo BAD_PASS;
|
|---|
| 39 | }
|
|---|
| 40 | }
|
|---|
| 41 | if (isset($_SESSION['pass'])) {
|
|---|
| 42 | if ($_SESSION['pass'] == $Config['webpass']) {
|
|---|
| 43 | //administrátorská část
|
|---|
| 44 | show_upload_mass(); //nahrání rozpisu
|
|---|
| 45 | save_file();
|
|---|
| 46 | show_article(5);
|
|---|
| 47 | }
|
|---|
| 48 | } else {
|
|---|
| 49 | show_login();
|
|---|
| 50 | }
|
|---|
| 51 |
|
|---|
| 52 |
|
|---|
| 53 | } else if (array_key_exists('img',$_GET)) {
|
|---|
| 54 | $file = $_GET['img'];
|
|---|
| 55 | echo '<img width="100%" src='.$file.' title="'."Soubor byl vložen " . date ("m d Y H:i:s.", filemtime($file)).'">';
|
|---|
| 56 |
|
|---|
| 57 |
|
|---|
| 58 | } else {
|
|---|
| 59 | echo HEADPAGE;
|
|---|
| 60 | show_article(0);
|
|---|
| 61 |
|
|---|
| 62 | }
|
|---|
| 63 |
|
|---|
| 64 | echo '</div>';
|
|---|
| 65 |
|
|---|
| 66 | show_footer();
|
|---|
| 67 | ?>
|
|---|
Note:
See
TracBrowser
for help on using the repository browser.