63bc9de30bb785622f3db93bd9fc5f3c0edc4ac4
Bernd Wurst Erste Version, die über die...

Bernd Wurst authored 4 years ago

1) <?php
Bernd Wurst Neue API 2023

Bernd Wurst authored 1 year ago

2) //print_r($_SESSION);
Bernd Wurst Erste Version, die über die...

Bernd Wurst authored 4 years ago

3) $pages = array(
4)     1 => 'index.php',
5)     2 => 'address.php',
Bernd Wurst Back-Button verwendet eine...

Bernd Wurst authored 1 month ago

6)     3 => 'notification.php',
7)     4 => 'gitterbox.php',
8)     5 => 'obstart.php',
9)     6 => 'gebrauchte.php',
10)     7 => 'auftrag.php',
11)     8 => 'frischsaft.php',
12)     9 => 'summary.php');
Bernd Wurst Erste Version, die über die...

Bernd Wurst authored 4 years ago

13) 
Bernd Wurst Back-Button verwendet eine...

Bernd Wurst authored 1 month ago

14) $previous = null;
15) $history_pos = 0;
16) if (!isset($_SESSION['page_history'])) {
17)     $_SESSION['page_history'] = [];
Bernd Wurst Erste Version, die über die...

Bernd Wurst authored 4 years ago

18) }
Bernd Wurst Back-Button verwendet eine...

Bernd Wurst authored 1 month ago

19) if (isset($_REQUEST['history_pos']) && $_REQUEST['history_pos'] >= 0) {
20)     if ($_REQUEST['history_pos'] > 0) {
21)         $previous = $_SESSION['page_history'][$_REQUEST['history_pos']-1];
22)     } 
23)     $history_pos = $_REQUEST['history_pos'];
24)     // Das tötet einen eventuellen Forward-Button
25)     // Wenn man zurück gedrückt hat, ist 
26)     array_pop($_SESSION['page_history']);
27) } else {
28)     $previous = end($_SESSION['page_history']);
29)     $_SESSION['page_history'][] = $_SERVER['PHP_SELF'];
30)     // Index ist count()-1
31)     $history_pos = count($_SESSION['page_history'])-1;
32) } 
33) 
Bernd Wurst Erste Version, die über die...

Bernd Wurst authored 4 years ago

34) 
35) ?><!DOCTYPE html>
Bernd Wurst Initial commit

Bernd Wurst authored 6 years ago

36) <html lang="de">
37)   <head>
38)     <meta charset="utf-8">
39)     <meta http-equiv="X-UA-Compatible" content="IE=edge">
40)     <meta name="viewport" content="width=device-width, initial-scale=1">
41)     <title>Mosterei Wurst - Auftrag erteilen</title>
42) 
43)     <script src="assets/jquery.js"></script>
44)     <script src="assets/jquery-ui/jquery-ui.min.js"></script>
45)     <link href="assets/jquery-ui/jquery-ui.min.css" rel="stylesheet">
Bernd Wurst Migration to bootstrap-4.0.0

Bernd Wurst authored 6 years ago

46)     <script src="assets/fontawesome/svg-with-js/js/fontawesome-all.min.js"></script>
47)     <link href="assets/fontawesome/svg-with-js/css/fa-svg-with-js.css" rel="stylesheet">
Bernd Wurst Initial commit

Bernd Wurst authored 6 years ago

48)     <script src="assets/bootstrap/js/bootstrap.min.js"></script>
49)     <link href="assets/bootstrap/css/bootstrap.min.css" rel="stylesheet">
50)     <link href="assets/style.css" rel="stylesheet">
51)     <script src="assets/script.js"></script>
52)     <?php
53)     $f = 'assets/'.str_replace('.php','.js', $_SERVER['PHP_SELF']);
54)     if (file_exists($f)) {
55)       echo '<script src="'.$f.'"></script>';
56)     }
57)     ?>
58)    </head>
Bernd Wurst Erste Version, die über die...

Bernd Wurst authored 4 years ago

59)   <body style="display: none;">
60)     <div id="banner" class="mb-3">
61)         <div id="banner-back">
62) <?php if ($previous) { ?>
Bernd Wurst Back-Button verwendet eine...

Bernd Wurst authored 1 month ago

63)        <a href="<?= $previous.'?history_pos='.($history_pos-1) ?>"><img src="assets/images/back.svg" width="65" height="65" alt="<"></a>
Bernd Wurst Erste Version, die über die...

Bernd Wurst authored 4 years ago

64) <?php } ?>
65)         </div>
66)         <div id="banner-logo"><img src="assets/images/banner.svg" width="244" height="65" alt="Mosterei Wurst - Murrhardt-Köchersberg - 07192-936436"></div>
Bernd Wurst Optimierungen für Handy-Dis...

Bernd Wurst authored 4 years ago

67)         <div id="banner-headline"><h1><?= $headline ?></h1></div>
68)         <div id="banner-clear"></div>
Bernd Wurst Erste Version, die über die...

Bernd Wurst authored 4 years ago

69)      </div>
Bernd Wurst Initial commit

Bernd Wurst authored 6 years ago

70)   <div class="container text-center">
Bernd Wurst API-Aufrufe über Guzzle um...

Bernd Wurst authored 1 year ago

71)     <?php
72)     if (isset($_SESSION['warnings'])) {
73)         foreach($_SESSION['warnings'] as $warning) {
74)             echo '<div class="card text-white bg-danger mb-3">
75)     <div class="card-header">Fehler</div>';
76)             echo '<div class="card-body">'.$warning.'</div>';
77)             echo ' </div>'; 
78)         }
79)     }?>
80) <?= $content ?>
Bernd Wurst Initial commit

Bernd Wurst authored 6 years ago

81)     <?php if (basename($_SERVER['PHP_SELF']) != 'finish.php') { ?>
Bernd Wurst Migration to bootstrap-4.0.0

Bernd Wurst authored 6 years ago

82)     <nav aria-label="Zu anderen Schritten springen">
83)         <ul class="pagination pagination-sm justify-content-center">
Bernd Wurst Initial commit

Bernd Wurst authored 6 years ago

84)         <?php 
Bernd Wurst Erste Version, die über die...

Bernd Wurst authored 4 years ago

85)        foreach ($pages as $index => $file) {   
86)             echo '<li class="page-item'.($file === basename($_SERVER['PHP_SELF']) ? ' active' : '').'"><a class="page-link" href="'.$file.'">'.$index.'</a></li>';
Bernd Wurst Spätere Anlieferung eingebaut

Bernd Wurst authored 6 years ago

87)         }
Bernd Wurst Initial commit

Bernd Wurst authored 6 years ago

88) ?>
Bernd Wurst Migration to bootstrap-4.0.0

Bernd Wurst authored 6 years ago

89)     </ul></nav>
90)     <a id="allesloeschen" data-toggle="modal" data-target="#allesloeschen-dialog"class="btn btn-sm btn-block btn-outline-danger" href="clear.php">Alle Eingaben löschen und von vorne beginnen</a>
91)     <div class="modal fade" id="allesloeschen-dialog" tabindex="-1" role="dialog" aria-labelledby="Bestaetigung" aria-hidden="true">
92)         <div class="modal-dialog">
93)             <div class="modal-content">
94)                 <div class="modal-header">
95)                     <h4 class="modal-title">Alle Eingaben löschen?</h4>
96)                 </div>
97) 
98)                 <div class="modal-body">
99)                     <p>Alles was Sie bisher eingegeben haben wird gelöscht und Sie möchten von vorne beginnen?</p>
100)                 </div>
101) 
102)                 <div class="modal-footer">
Bernd Wurst Fehlermeldungen auf BS4 por...

Bernd Wurst authored 6 years ago

103)                     <button type="button" class="btn btn-outline-secondary" data-dismiss="modal">Abbrechen</button>
Bernd Wurst Migration to bootstrap-4.0.0

Bernd Wurst authored 6 years ago

104)                     <a class="btn btn-danger btn-ok">Eingaben löschen</a>
105)                 </div>
106)             </div>
107)         </div>
108)     </div>
109)     <div class="card" id="footer">
110)         <div class="card-header">Hilfe?</div>
Bernd Wurst Session zerstören wenn der...

Bernd Wurst authored 2 months ago

111)         <div class="card-body"><p class="card-text">Für Unterstützung bei der Nutzung dieses Formulars können Sie uns unter der Telefonnummer 
112)         <?php if (!isset($_SESSION['mode']) || $_SESSION['mode'] != 'local') { 
113)             echo '<a href="tel:+497192936434">07192-936434</a>';
114)         } else {
115)             echo '07192-936434';
116)         }?>
117)         erreichen.</p></div>
Bernd Wurst Schrift größer, Buttons mit...

Bernd Wurst authored 1 year ago

118) <?php if (!isset($_SESSION['mode']) || $_SESSION['mode'] != 'local') { ?>
Bernd Wurst Erste Version, die über die...

Bernd Wurst authored 4 years ago

119)     <div class="card-footer"><a target="_blank" href="https://mosterei-wurst.de/impressum/">Impressum</a> · <a target="_blank" href="https://mosterei-wurst.de/">Website besuchen</a></div>
120) <?php } /* if ($_SESSION['mode'] != 'local') */ ?>
Bernd Wurst Initial commit

Bernd Wurst authored 6 years ago

121)     </div>
Bernd Wurst Erste Version, die über die...

Bernd Wurst authored 4 years ago

122) <?php } /* if (basename($_SERVER['PHP_SELF']) != 'finish.php') */ ?>
Bernd Wurst Initial commit

Bernd Wurst authored 6 years ago

123) 
124)     </div>
Bernd Wurst API-Authtoken, Idle-Warnung...

Bernd Wurst authored 4 years ago

125)     <div class="modal fade" id="idle-dialog" tabindex="-1" role="dialog" aria-labelledby="Bestaetigung" aria-hidden="true">
126)         <div class="modal-dialog">
127)             <div class="modal-content">
128)                 <div class="modal-header">
129)                     <h4 class="modal-title">Weitermachen?</h4>
130)                 </div>
131) 
132)                 <div class="modal-body">
133)                     <p>An diesem Gerät wurde lange nichts eingegeben. Möchten Sie am laufenden Auftrag weiter machen oder neu beginnen?</p>
134)                 </div>
Bernd Wurst Initial commit

Bernd Wurst authored 6 years ago

135) 
Bernd Wurst API-Authtoken, Idle-Warnung...

Bernd Wurst authored 4 years ago

136)                 <div class="modal-footer">
137)                     <button type="button" class="btn btn-primary" data-dismiss="modal" id="dismiss-idle">Weiter machen!</button>
138)                     <a class="btn btn-danger btn-ok" href="clear.php<?= (isset($_SESSION['mode']) ? '?mode='.$_SESSION['mode'] : '') ?>">Neu beginnen</a>
139)                 </div>
140)             </div>
141)         </div>
142)     </div>
143)  
Bernd Wurst loading-spinner hinzugefügt

Bernd Wurst authored 1 year ago

144)     <div id="loading-spinner-overlay">
145)         <svg id="loading-spinner" xmlns="http://www.w3.org/2000/svg" height="1em" viewBox="0 0 512 512"><!--! Font Awesome Free 6.4.2 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license (Commercial License) Copyright 2023 Fonticons, Inc. --><path d="M304 48a48 48 0 1 0 -96 0 48 48 0 1 0 96 0zm0 416a48 48 0 1 0 -96 0 48 48 0 1 0 96 0zM48 304a48 48 0 1 0 0-96 48 48 0 1 0 0 96zm464-48a48 48 0 1 0 -96 0 48 48 0 1 0 96 0zM142.9 437A48 48 0 1 0 75 369.1 48 48 0 1 0 142.9 437zm0-294.2A48 48 0 1 0 75 75a48 48 0 1 0 67.9 67.9zM369.1 437A48 48 0 1 0 437 369.1 48 48 0 1 0 369.1 437z"/></svg>
146)     </div>
147)