@@ -40,7 +40,7 @@ |
||
| 40 | 40 | */ |
| 41 | 41 | public static function lookupDecimal($int) |
| 42 | 42 | { |
| 43 | - $entity = '&#' . $int . ';'; |
|
| 43 | + $entity = '&#'.$int.';'; |
|
| 44 | 44 | |
| 45 | 45 | // UNTESTED: This may fail on some planes. Couldn't find full documentation |
| 46 | 46 | // on the value of the mask array. |
@@ -239,7 +239,7 @@ discard block |
||
| 239 | 239 | return $this->text($tok); |
| 240 | 240 | } |
| 241 | 241 | |
| 242 | - $sequence = '</' . $this->untilTag . '>'; |
|
| 242 | + $sequence = '</'.$this->untilTag.'>'; |
|
| 243 | 243 | $txt = $this->readUntilSequence($sequence); |
| 244 | 244 | $this->events->text($txt); |
| 245 | 245 | $this->setTextMode(0); |
@@ -260,7 +260,7 @@ discard block |
||
| 260 | 260 | return $this->text($tok); |
| 261 | 261 | } |
| 262 | 262 | |
| 263 | - $sequence = '</' . $this->untilTag; |
|
| 263 | + $sequence = '</'.$this->untilTag; |
|
| 264 | 264 | $txt = ''; |
| 265 | 265 | |
| 266 | 266 | $caseSensitive = !Elements::isHtml5Element($this->untilTag); |
@@ -572,11 +572,11 @@ discard block |
||
| 572 | 572 | */ |
| 573 | 573 | protected function quotedAttributeValue($quote) |
| 574 | 574 | { |
| 575 | - $stoplist = "\f" . $quote; |
|
| 575 | + $stoplist = "\f".$quote; |
|
| 576 | 576 | $val = ''; |
| 577 | 577 | |
| 578 | 578 | while (true) { |
| 579 | - $tokens = $this->scanner->charsUntil($stoplist . '&'); |
|
| 579 | + $tokens = $this->scanner->charsUntil($stoplist.'&'); |
|
| 580 | 580 | if (false !== $tokens) { |
| 581 | 581 | $val .= $tokens; |
| 582 | 582 | } else { |
@@ -740,7 +740,7 @@ discard block |
||
| 740 | 740 | if (strcasecmp($chars, 'DOCTYPE')) { |
| 741 | 741 | $this->parseError('Expected DOCTYPE, got %s', $chars); |
| 742 | 742 | |
| 743 | - return $this->bogusComment('<!' . $chars); |
|
| 743 | + return $this->bogusComment('<!'.$chars); |
|
| 744 | 744 | } |
| 745 | 745 | |
| 746 | 746 | $this->scanner->whitespace(); |
@@ -855,7 +855,7 @@ discard block |
||
| 855 | 855 | $tok = $this->scanner->current(); |
| 856 | 856 | if ('"' == $tok || "'" == $tok) { |
| 857 | 857 | $this->scanner->next(); |
| 858 | - $ret = $this->scanner->charsUntil($tok . $stopchars); |
|
| 858 | + $ret = $this->scanner->charsUntil($tok.$stopchars); |
|
| 859 | 859 | if ($this->scanner->current() == $tok) { |
| 860 | 860 | $this->scanner->next(); |
| 861 | 861 | } else { |
@@ -886,14 +886,14 @@ discard block |
||
| 886 | 886 | if ('CDATA' != $chars || '[' != $this->scanner->current()) { |
| 887 | 887 | $this->parseError('Expected [CDATA[, got %s', $chars); |
| 888 | 888 | |
| 889 | - return $this->bogusComment('<![' . $chars); |
|
| 889 | + return $this->bogusComment('<!['.$chars); |
|
| 890 | 890 | } |
| 891 | 891 | |
| 892 | 892 | $tok = $this->scanner->next(); |
| 893 | 893 | do { |
| 894 | 894 | if (false === $tok) { |
| 895 | 895 | $this->parseError('Unexpected EOF inside CDATA.'); |
| 896 | - $this->bogusComment('<![CDATA[' . $cdata); |
|
| 896 | + $this->bogusComment('<![CDATA['.$cdata); |
|
| 897 | 897 | |
| 898 | 898 | return true; |
| 899 | 899 | } |
@@ -936,7 +936,7 @@ discard block |
||
| 936 | 936 | // If not a PI, send to bogusComment. |
| 937 | 937 | if (0 == strlen($procName) || 0 == $white || false == $this->scanner->current()) { |
| 938 | 938 | $this->parseError("Expected processing instruction name, got $tok"); |
| 939 | - $this->bogusComment('<?' . $tok . $procName); |
|
| 939 | + $this->bogusComment('<?'.$tok.$procName); |
|
| 940 | 940 | |
| 941 | 941 | return true; |
| 942 | 942 | } |
@@ -1017,7 +1017,7 @@ discard block |
||
| 1017 | 1017 | */ |
| 1018 | 1018 | protected function sequenceMatches($sequence, $caseSensitive = true) |
| 1019 | 1019 | { |
| 1020 | - @trigger_error(__METHOD__ . ' method is deprecated since version 2.4 and will be removed in 3.0. Use Scanner::sequenceMatches() instead.', E_USER_DEPRECATED); |
|
| 1020 | + @trigger_error(__METHOD__.' method is deprecated since version 2.4 and will be removed in 3.0. Use Scanner::sequenceMatches() instead.', E_USER_DEPRECATED); |
|
| 1021 | 1021 | |
| 1022 | 1022 | return $this->scanner->sequenceMatches($sequence, $caseSensitive); |
| 1023 | 1023 | } |
@@ -1098,7 +1098,7 @@ discard block |
||
| 1098 | 1098 | |
| 1099 | 1099 | // These indicate not an entity. We return just |
| 1100 | 1100 | // the &. |
| 1101 | - if (1 === strspn($tok, static::WHITE . '&<')) { |
|
| 1101 | + if (1 === strspn($tok, static::WHITE.'&<')) { |
|
| 1102 | 1102 | // $this->scanner->next(); |
| 1103 | 1103 | return '&'; |
| 1104 | 1104 | } |
@@ -1180,6 +1180,6 @@ discard block |
||
| 1180 | 1180 | |
| 1181 | 1181 | $this->parseError('Expected &ENTITY;, got &ENTITY%s (no trailing ;) ', $tok); |
| 1182 | 1182 | |
| 1183 | - return '&' . $entity; |
|
| 1183 | + return '&'.$entity; |
|
| 1184 | 1184 | } |
| 1185 | 1185 | } |
@@ -245,7 +245,7 @@ discard block |
||
| 245 | 245 | $this->quirks = $quirks; |
| 246 | 246 | |
| 247 | 247 | if ($this->insertMode > static::IM_INITIAL) { |
| 248 | - $this->parseError('Illegal placement of DOCTYPE tag. Ignoring: ' . $name); |
|
| 248 | + $this->parseError('Illegal placement of DOCTYPE tag. Ignoring: '.$name); |
|
| 249 | 249 | |
| 250 | 250 | return; |
| 251 | 251 | } |
@@ -362,7 +362,7 @@ discard block |
||
| 362 | 362 | $prefix = ($pos = strpos($lname, ':')) ? substr($lname, 0, $pos) : ''; |
| 363 | 363 | |
| 364 | 364 | if (false !== $needsWorkaround) { |
| 365 | - $xml = "<$lname xmlns=\"$needsWorkaround\" " . (strlen($prefix) && isset($this->nsStack[0][$prefix]) ? ("xmlns:$prefix=\"" . $this->nsStack[0][$prefix] . '"') : '') . '/>'; |
|
| 365 | + $xml = "<$lname xmlns=\"$needsWorkaround\" ".(strlen($prefix) && isset($this->nsStack[0][$prefix]) ? ("xmlns:$prefix=\"".$this->nsStack[0][$prefix].'"') : '').'/>'; |
|
| 366 | 366 | |
| 367 | 367 | $frag = new \DOMDocument('1.0', 'UTF-8'); |
| 368 | 368 | $frag->loadXML($xml); |
@@ -531,7 +531,7 @@ discard block |
||
| 531 | 531 | } |
| 532 | 532 | |
| 533 | 533 | if (!$this->autoclose($lname)) { |
| 534 | - $this->parseError('Could not find closing tag for ' . $lname); |
|
| 534 | + $this->parseError('Could not find closing tag for '.$lname); |
|
| 535 | 535 | } |
| 536 | 536 | |
| 537 | 537 | switch ($lname) { |
@@ -566,7 +566,7 @@ discard block |
||
| 566 | 566 | $dataTmp = trim($data, " \t\n\r\f"); |
| 567 | 567 | if (!empty($dataTmp)) { |
| 568 | 568 | // fprintf(STDOUT, "Unexpected insert mode: %d", $this->insertMode); |
| 569 | - $this->parseError('Unexpected text. Ignoring: ' . $dataTmp); |
|
| 569 | + $this->parseError('Unexpected text. Ignoring: '.$dataTmp); |
|
| 570 | 570 | } |
| 571 | 571 | |
| 572 | 572 | return; |