@@ -58,7 +58,7 @@ |
||
58 | 58 | if ($value === false) { |
59 | 59 | continue; |
60 | 60 | } |
61 | - $int = (int)$value; |
|
61 | + $int = (int) $value; |
|
62 | 62 | if ($int > 100) { |
63 | 63 | $value = '100'; |
64 | 64 | } |
@@ -32,7 +32,7 @@ |
||
32 | 32 | $final = ''; |
33 | 33 | foreach ($parts as $part) { |
34 | 34 | if (isset($allowed_values[$part])) { |
35 | - $final .= $part . ' '; |
|
35 | + $final .= $part.' '; |
|
36 | 36 | } |
37 | 37 | } |
38 | 38 | $final = rtrim($final); |
@@ -61,7 +61,7 @@ |
||
61 | 61 | 'a', |
62 | 62 | array('href' => str_replace('%s', $bits[$i], $this->docURL)) |
63 | 63 | ); |
64 | - $token[] = new HTMLPurifier_Token_Text('%' . $bits[$i]); |
|
64 | + $token[] = new HTMLPurifier_Token_Text('%'.$bits[$i]); |
|
65 | 65 | $token[] = new HTMLPurifier_Token_End('a'); |
66 | 66 | } |
67 | 67 | } |
@@ -97,7 +97,7 @@ |
||
97 | 97 | break; |
98 | 98 | } |
99 | 99 | // This is safe because we removed the token that triggered this. |
100 | - $this->rewindOffset($b+$deleted); |
|
100 | + $this->rewindOffset($b + $deleted); |
|
101 | 101 | return; |
102 | 102 | } |
103 | 103 | } |
@@ -81,9 +81,13 @@ |
||
81 | 81 | if (isset($this->exclude[$token->name])) { |
82 | 82 | $r = true; |
83 | 83 | foreach ($this->exclude[$token->name] as $elem) { |
84 | - if (!isset($token->attr[$elem])) $r = false; |
|
84 | + if (!isset($token->attr[$elem])) { |
|
85 | + $r = false; |
|
86 | + } |
|
85 | 87 | } |
86 | - if ($r) return; |
|
88 | + if ($r) { |
|
89 | + return; |
|
90 | + } |
|
87 | 91 | } |
88 | 92 | if (isset($token->attr['id']) || isset($token->attr['name'])) { |
89 | 93 | return; |
@@ -118,7 +118,7 @@ |
||
118 | 118 | $line = trim($line); |
119 | 119 | } else { |
120 | 120 | // Use default declaration |
121 | - $state = $this->default; |
|
121 | + $state = $this->default; |
|
122 | 122 | } |
123 | 123 | } |
124 | 124 | if ($single) { |
@@ -37,7 +37,7 @@ |
||
37 | 37 | if (ctype_digit($length)) { |
38 | 38 | $length .= 'px'; |
39 | 39 | } |
40 | - $this->prependCSS($attr, $this->cssName . ":$length;"); |
|
40 | + $this->prependCSS($attr, $this->cssName.":$length;"); |
|
41 | 41 | return $attr; |
42 | 42 | } |
43 | 43 | } |
@@ -35,7 +35,7 @@ |
||
35 | 35 | { |
36 | 36 | $this->attr = $attr; |
37 | 37 | $this->enumToCSS = $enum_to_css; |
38 | - $this->caseSensitive = (bool)$case_sensitive; |
|
38 | + $this->caseSensitive = (bool) $case_sensitive; |
|
39 | 39 | } |
40 | 40 | |
41 | 41 | /** |
@@ -25,7 +25,7 @@ |
||
25 | 25 | { |
26 | 26 | $this->attr = $attr; |
27 | 27 | if (!isset($this->css[$attr])) { |
28 | - trigger_error(htmlspecialchars($attr) . ' is not valid space attribute'); |
|
28 | + trigger_error(htmlspecialchars($attr).' is not valid space attribute'); |
|
29 | 29 | } |
30 | 30 | } |
31 | 31 |
@@ -68,7 +68,7 @@ |
||
68 | 68 | */ |
69 | 69 | public static function makeFromSerial() |
70 | 70 | { |
71 | - $contents = file_get_contents(HTMLPURIFIER_PREFIX . '/HTMLPurifier/ConfigSchema/schema.ser'); |
|
71 | + $contents = file_get_contents(HTMLPURIFIER_PREFIX.'/HTMLPurifier/ConfigSchema/schema.ser'); |
|
72 | 72 | $r = unserialize($contents); |
73 | 73 | if (!$r) { |
74 | 74 | $hash = sha1($contents); |