@@ -2,7 +2,7 @@ |
||
2 | 2 | class Page01 extends Template { |
3 | 3 | public function __construct() { |
4 | 4 | parent::__construct(); |
5 | - $this->tags["title"] = "JATE - Page01"; |
|
5 | + $this->tags["title"] = "JATE - Page01"; |
|
6 | 6 | $this->tags["content"] = $this->makePage(); |
7 | 7 | } |
8 | 8 | public function makePage() { |
@@ -2,7 +2,7 @@ |
||
2 | 2 | class Home extends Template { |
3 | 3 | public function __construct() { |
4 | 4 | parent::__construct(); |
5 | - $this->tags["title"] = "JATE - Home"; |
|
5 | + $this->tags["title"] = "JATE - Home"; |
|
6 | 6 | $this->tags["content"] = $this->makePage(); |
7 | 7 | } |
8 | 8 | public function makePage() { |
@@ -2,7 +2,7 @@ |
||
2 | 2 | class Page404 extends Template { |
3 | 3 | public function __construct() { |
4 | 4 | parent::__construct(); |
5 | - $this->tags["title"] = "JATE - 404"; |
|
5 | + $this->tags["title"] = "JATE - 404"; |
|
6 | 6 | $this->tags["content"] = $this->makePage(); |
7 | 7 | } |
8 | 8 | public function makePage() { |
@@ -2,7 +2,7 @@ |
||
2 | 2 | class Page01 extends Template { |
3 | 3 | public function __construct() { |
4 | 4 | parent::__construct(); |
5 | - $this->tags["title"] = "JATE - Page01"; |
|
5 | + $this->tags["title"] = "JATE - Page01"; |
|
6 | 6 | $this->tags["content"] = $this->makePage(); |
7 | 7 | } |
8 | 8 | public function makePage() { |
@@ -2,7 +2,7 @@ |
||
2 | 2 | class Home extends Template { |
3 | 3 | public function __construct() { |
4 | 4 | parent::__construct(); |
5 | - $this->tags["title"] = "JATE - Home"; |
|
5 | + $this->tags["title"] = "JATE - Home"; |
|
6 | 6 | $this->tags["content"] = $this->makePage(); |
7 | 7 | } |
8 | 8 | public function makePage() { |
@@ -2,7 +2,7 @@ |
||
2 | 2 | class Page404 extends Template { |
3 | 3 | public function __construct() { |
4 | 4 | parent::__construct(); |
5 | - $this->tags["title"] = "JATE - 404"; |
|
5 | + $this->tags["title"] = "JATE - 404"; |
|
6 | 6 | $this->tags["content"] = $this->makePage(); |
7 | 7 | } |
8 | 8 | public function makePage() { |
@@ -1,27 +1,27 @@ discard block |
||
1 | 1 | <?php |
2 | 2 | function utf8ize($_array) { |
3 | - return travelStringArray($_array,"utf8_encode"); |
|
3 | + return travelStringArray($_array, "utf8_encode"); |
|
4 | 4 | } |
5 | 5 | function unutf8ize($_array) { |
6 | - return travelStringArray($_array,"utf8_decode"); |
|
6 | + return travelStringArray($_array, "utf8_decode"); |
|
7 | 7 | } |
8 | 8 | function arraySlash($_array) { |
9 | - return travelStringArray($_array,"addslashes"); |
|
9 | + return travelStringArray($_array, "addslashes"); |
|
10 | 10 | } |
11 | 11 | function arrayHtmlParser($_array) { |
12 | - return travelStringArray($_array,"htmlParser"); |
|
12 | + return travelStringArray($_array, "htmlParser"); |
|
13 | 13 | } |
14 | - function travelStringArray ( $_array, $_function ) { |
|
14 | + function travelStringArray($_array, $_function) { |
|
15 | 15 | if (is_array($_array)) { |
16 | 16 | foreach ($_array as $k => $v) { |
17 | 17 | $_array[$k] = travelStringArray($v, $_function); |
18 | 18 | } |
19 | - } else if (is_string ($_array)) { |
|
20 | - return call_user_func($_function,$_array); |
|
19 | + } else if (is_string($_array)) { |
|
20 | + return call_user_func($_function, $_array); |
|
21 | 21 | } |
22 | 22 | return $_array; |
23 | 23 | } |
24 | - function arrayDepth( $_array ) { |
|
24 | + function arrayDepth($_array) { |
|
25 | 25 | $maxDepth = 1; |
26 | 26 | foreach ($_array as $value) { |
27 | 27 | if (is_array($value)) { |
@@ -33,12 +33,12 @@ discard block |
||
33 | 33 | } |
34 | 34 | return $maxDepth; |
35 | 35 | } |
36 | - function arrayDump( $_array, $_name = "Array", $_tab = " " ) { |
|
36 | + function arrayDump($_array, $_name = "Array", $_tab = " ") { |
|
37 | 37 | $position = preg_replace('/ /', '', $_tab, 1); |
38 | 38 | echo "$position<span style=\"color:rgb(230,0,0)\">$_name:</span><br>"; |
39 | 39 | foreach ($_array as $k => $i) |
40 | - if(is_array($i)) |
|
41 | - arrayDump( $i, $k, " $_tab" ); |
|
40 | + if (is_array($i)) |
|
41 | + arrayDump($i, $k, " $_tab"); |
|
42 | 42 | else |
43 | 43 | echo "$_tab<b>$k:</b> $i<br>"; |
44 | 44 | } |
@@ -36,10 +36,12 @@ |
||
36 | 36 | function arrayDump( $_array, $_name = "Array", $_tab = " " ) { |
37 | 37 | $position = preg_replace('/ /', '', $_tab, 1); |
38 | 38 | echo "$position<span style=\"color:rgb(230,0,0)\">$_name:</span><br>"; |
39 | - foreach ($_array as $k => $i) |
|
40 | - if(is_array($i)) |
|
39 | + foreach ($_array as $k => $i) { |
|
40 | + if(is_array($i)) |
|
41 | 41 | arrayDump( $i, $k, " $_tab" ); |
42 | - else |
|
43 | - echo "$_tab<b>$k:</b> $i<br>"; |
|
42 | + } |
|
43 | + else { |
|
44 | + echo "$_tab<b>$k:</b> $i<br>"; |
|
45 | + } |
|
44 | 46 | } |
45 | 47 | ?> |
@@ -4,10 +4,10 @@ |
||
4 | 4 | parent::__construct(); |
5 | 5 | } |
6 | 6 | public function getPage() { |
7 | - $base = $_SERVER["REDIRECT_BASE"]; |
|
8 | - $request = $_SERVER["REQUEST_URI"]; |
|
7 | + $base = $_SERVER["REDIRECT_BASE"]; |
|
8 | + $request = $_SERVER["REQUEST_URI"]; |
|
9 | 9 | $url = str_replace($base, "", $request); |
10 | - $url = explode("/",$url); |
|
10 | + $url = explode("/", $url); |
|
11 | 11 | return $url[1]; |
12 | 12 | } |
13 | 13 | } |