@@ -17,8 +17,12 @@ discard block |
||
17 | 17 | $basePath = implode('/', $basePath); |
18 | 18 | $url = 'http://'.$_SERVER['SERVER_NAME'].$basePath.'/7.php?wsdl'; |
19 | 19 | |
20 | -if (!isset($_GET['y'])) $_GET['y'] = date('Y'); |
|
21 | -if (!isset($_GET['m'])) $_GET['m'] = date('n'); |
|
20 | +if (!isset($_GET['y'])) { |
|
21 | + $_GET['y'] = date('Y'); |
|
22 | +} |
|
23 | +if (!isset($_GET['m'])) { |
|
24 | + $_GET['m'] = date('n'); |
|
25 | +} |
|
22 | 26 | |
23 | 27 | $wsdl = new SOAP_WSDL ($url); |
24 | 28 | |
@@ -47,16 +51,18 @@ discard block |
||
47 | 51 | <?php |
48 | 52 | foreach ( $month->days as $day ) { |
49 | 53 | |
50 | - if ( $day->isFirst === 1 ) |
|
51 | - echo ( "<tr>\n" ); |
|
54 | + if ( $day->isFirst === 1 ) { |
|
55 | + echo ( "<tr>\n" ); |
|
56 | + } |
|
52 | 57 | if ( $day->isEmpty === 1 ) { |
53 | 58 | echo ( "<td></td>" ); |
54 | 59 | } else { |
55 | 60 | echo ( "<td>".$day->day."</td>" ); |
56 | 61 | } |
57 | - if ( $day->isLast === 1 ) |
|
58 | - echo ( "</tr>\n" ); |
|
59 | -} |
|
62 | + if ( $day->isLast === 1 ) { |
|
63 | + echo ( "</tr>\n" ); |
|
64 | + } |
|
65 | + } |
|
60 | 66 | ?> |
61 | 67 | <tr> |
62 | 68 | </table> |
@@ -17,7 +17,9 @@ |
||
17 | 17 | |
18 | 18 | define ('CALENDAR_MONTH_STATE',CALENDAR_USE_MONTH_WEEKS); |
19 | 19 | |
20 | -if (!isset($_GET['year'])) $_GET['year'] = date('Y'); |
|
20 | +if (!isset($_GET['year'])) { |
|
21 | + $_GET['year'] = date('Y'); |
|
22 | +} |
|
21 | 23 | |
22 | 24 | $week_types = array( |
23 | 25 | 'n_in_year', |
@@ -13,8 +13,12 @@ |
||
13 | 13 | require_once CALENDAR_ROOT.'Util'.DIRECTORY_SEPARATOR.'Uri.php'; |
14 | 14 | require_once CALENDAR_ROOT.'Util'.DIRECTORY_SEPARATOR.'Textual.php'; |
15 | 15 | |
16 | -if (!isset($_GET['y'])) $_GET['y'] = date('Y'); |
|
17 | -if (!isset($_GET['m'])) $_GET['m'] = date('m'); |
|
16 | +if (!isset($_GET['y'])) { |
|
17 | + $_GET['y'] = date('Y'); |
|
18 | +} |
|
19 | +if (!isset($_GET['m'])) { |
|
20 | + $_GET['m'] = date('m'); |
|
21 | +} |
|
18 | 22 | |
19 | 23 | // Build a month |
20 | 24 | $Month = & new Calendar_Month_Weekdays($_GET['y'],$_GET['m']); |
@@ -15,9 +15,15 @@ discard block |
||
15 | 15 | require_once CALENDAR_ROOT.'Month/Weekdays.php'; |
16 | 16 | require_once CALENDAR_ROOT.'Day.php'; |
17 | 17 | |
18 | -if (!isset($_GET['y'])) $_GET['y'] = date('Y'); |
|
19 | -if (!isset($_GET['m'])) $_GET['m'] = date('m'); |
|
20 | -if (!isset($_GET['d'])) $_GET['d'] = date('d'); |
|
18 | +if (!isset($_GET['y'])) { |
|
19 | + $_GET['y'] = date('Y'); |
|
20 | +} |
|
21 | +if (!isset($_GET['m'])) { |
|
22 | + $_GET['m'] = date('m'); |
|
23 | +} |
|
24 | +if (!isset($_GET['d'])) { |
|
25 | + $_GET['d'] = date('d'); |
|
26 | +} |
|
21 | 27 | |
22 | 28 | // Build the month |
23 | 29 | $Month = new Calendar_Month_Weekdays($_GET['y'],$_GET['m']); |
@@ -101,8 +107,9 @@ discard block |
||
101 | 107 | '&d='.$Day->thisDay(); |
102 | 108 | |
103 | 109 | // isFirst() to find start of week |
104 | - if ( $Day->isFirst() ) |
|
105 | - echo ( "<tr>\n" ); |
|
110 | + if ( $Day->isFirst() ) { |
|
111 | + echo ( "<tr>\n" ); |
|
112 | + } |
|
106 | 113 | |
107 | 114 | if ( $Day->isSelected() ) { |
108 | 115 | echo ( "<td class=\"selected\">".$Day->thisDay()."</td>\n" ); |
@@ -113,9 +120,10 @@ discard block |
||
113 | 120 | } |
114 | 121 | |
115 | 122 | // isLast() to find end of week |
116 | - if ( $Day->isLast() ) |
|
117 | - echo ( "</tr>\n" ); |
|
118 | -} |
|
123 | + if ( $Day->isLast() ) { |
|
124 | + echo ( "</tr>\n" ); |
|
125 | + } |
|
126 | + } |
|
119 | 127 | ?> |
120 | 128 | <tr> |
121 | 129 | <td> |
@@ -17,12 +17,24 @@ |
||
17 | 17 | define('CALENDAR_ROOT','../../'); |
18 | 18 | } |
19 | 19 | |
20 | -if (!isset($_GET['y'])) $_GET['y'] = 2003; |
|
21 | -if (!isset($_GET['m'])) $_GET['m'] = 8; |
|
22 | -if (!isset($_GET['d'])) $_GET['d'] = 9; |
|
23 | -if (!isset($_GET['h'])) $_GET['h'] = 12; |
|
24 | -if (!isset($_GET['i'])) $_GET['i'] = 34; |
|
25 | -if (!isset($_GET['s'])) $_GET['s'] = 46; |
|
20 | +if (!isset($_GET['y'])) { |
|
21 | + $_GET['y'] = 2003; |
|
22 | +} |
|
23 | +if (!isset($_GET['m'])) { |
|
24 | + $_GET['m'] = 8; |
|
25 | +} |
|
26 | +if (!isset($_GET['d'])) { |
|
27 | + $_GET['d'] = 9; |
|
28 | +} |
|
29 | +if (!isset($_GET['h'])) { |
|
30 | + $_GET['h'] = 12; |
|
31 | +} |
|
32 | +if (!isset($_GET['i'])) { |
|
33 | + $_GET['i'] = 34; |
|
34 | +} |
|
35 | +if (!isset($_GET['s'])) { |
|
36 | + $_GET['s'] = 46; |
|
37 | +} |
|
26 | 38 | |
27 | 39 | switch ( @$_GET['view'] ) { |
28 | 40 | default: |
@@ -13,9 +13,15 @@ |
||
13 | 13 | } |
14 | 14 | require_once CALENDAR_ROOT.'Week.php'; |
15 | 15 | |
16 | -if (!isset($_GET['y'])) $_GET['y'] = date('Y'); |
|
17 | -if (!isset($_GET['m'])) $_GET['m'] = date('m'); |
|
18 | -if (!isset($_GET['d'])) $_GET['d'] = 1; |
|
16 | +if (!isset($_GET['y'])) { |
|
17 | + $_GET['y'] = date('Y'); |
|
18 | +} |
|
19 | +if (!isset($_GET['m'])) { |
|
20 | + $_GET['m'] = date('m'); |
|
21 | +} |
|
22 | +if (!isset($_GET['d'])) { |
|
23 | + $_GET['d'] = 1; |
|
24 | +} |
|
19 | 25 | |
20 | 26 | // Build the month |
21 | 27 | $Week = new Calendar_Week($_GET['y'], $_GET['m'], $_GET['d']); |
@@ -19,9 +19,15 @@ |
||
19 | 19 | require_once CALENDAR_ROOT.'Day.php'; |
20 | 20 | |
21 | 21 | // Initialize GET variables if not set |
22 | -if (!isset($_GET['y'])) $_GET['y'] = date('Y'); |
|
23 | -if (!isset($_GET['m'])) $_GET['m'] = date('m'); |
|
24 | -if (!isset($_GET['d'])) $_GET['d'] = date('d'); |
|
22 | +if (!isset($_GET['y'])) { |
|
23 | + $_GET['y'] = date('Y'); |
|
24 | +} |
|
25 | +if (!isset($_GET['m'])) { |
|
26 | + $_GET['m'] = date('m'); |
|
27 | +} |
|
28 | +if (!isset($_GET['d'])) { |
|
29 | + $_GET['d'] = date('d'); |
|
30 | +} |
|
25 | 31 | |
26 | 32 | // Build a month object |
27 | 33 | $Month = new Calendar_Month_Weeks($_GET['y'], $_GET['m']); |
@@ -8,8 +8,12 @@ |
||
8 | 8 | require_once CALENDAR_ROOT.'Month/Weekdays.php'; |
9 | 9 | require_once CALENDAR_ROOT.'Util/Uri.php'; |
10 | 10 | |
11 | -if (!isset($_GET['jahr'])) $_GET['jahr'] = date('Y'); |
|
12 | -if (!isset($_GET['monat'])) $_GET['monat'] = date('m'); |
|
11 | +if (!isset($_GET['jahr'])) { |
|
12 | + $_GET['jahr'] = date('Y'); |
|
13 | +} |
|
14 | +if (!isset($_GET['monat'])) { |
|
15 | + $_GET['monat'] = date('m'); |
|
16 | +} |
|
13 | 17 | |
14 | 18 | // Build the month |
15 | 19 | $Calendar = new Calendar_Month_Weekdays($_GET['jahr'], $_GET['monat']); |
@@ -13,12 +13,24 @@ |
||
13 | 13 | } |
14 | 14 | require_once CALENDAR_ROOT.'Second.php'; |
15 | 15 | |
16 | -if (!isset($_GET['y'])) $_GET['y'] = date('Y'); |
|
17 | -if (!isset($_GET['m'])) $_GET['m'] = date('n'); |
|
18 | -if (!isset($_GET['d'])) $_GET['d'] = date('j'); |
|
19 | -if (!isset($_GET['h'])) $_GET['h'] = date('H'); |
|
20 | -if (!isset($_GET['i'])) $_GET['i'] = date('i'); |
|
21 | -if (!isset($_GET['s'])) $_GET['s'] = date('s'); |
|
16 | +if (!isset($_GET['y'])) { |
|
17 | + $_GET['y'] = date('Y'); |
|
18 | +} |
|
19 | +if (!isset($_GET['m'])) { |
|
20 | + $_GET['m'] = date('n'); |
|
21 | +} |
|
22 | +if (!isset($_GET['d'])) { |
|
23 | + $_GET['d'] = date('j'); |
|
24 | +} |
|
25 | +if (!isset($_GET['h'])) { |
|
26 | + $_GET['h'] = date('H'); |
|
27 | +} |
|
28 | +if (!isset($_GET['i'])) { |
|
29 | + $_GET['i'] = date('i'); |
|
30 | +} |
|
31 | +if (!isset($_GET['s'])) { |
|
32 | + $_GET['s'] = date('s'); |
|
33 | +} |
|
22 | 34 | |
23 | 35 | $Unit = & new Calendar_Second($_GET['y'], $_GET['m'], $_GET['d'], $_GET['h'], $_GET['i'], $_GET['s']); |
24 | 36 |