@@ -1,7 +1,7 @@ |
||
| 1 | 1 | <?php |
| 2 | 2 | /** |
| 3 | - * Provide general element functions. |
|
| 4 | - */ |
|
| 3 | + * Provide general element functions. |
|
| 4 | + */ |
|
| 5 | 5 | namespace Masterminds\Html5; |
| 6 | 6 | |
| 7 | 7 | /** |
@@ -344,8 +344,8 @@ discard block |
||
| 344 | 344 | } |
| 345 | 345 | |
| 346 | 346 | if ($this->onlyInline && Elements::isA($lname, Elements::BLOCK_TAG)) { |
| 347 | - $this->autoclose($this->onlyInline); |
|
| 348 | - $this->onlyInline = null; |
|
| 347 | + $this->autoclose($this->onlyInline); |
|
| 348 | + $this->onlyInline = null; |
|
| 349 | 349 | } |
| 350 | 350 | |
| 351 | 351 | try { |
@@ -375,7 +375,7 @@ discard block |
||
| 375 | 375 | } |
| 376 | 376 | |
| 377 | 377 | if (Elements::isA($lname, Elements::BLOCK_ONLY_INLINE)) { |
| 378 | - $this->onlyInline = $lname; |
|
| 378 | + $this->onlyInline = $lname; |
|
| 379 | 379 | } |
| 380 | 380 | |
| 381 | 381 | // When we add some namespacess, we have to track them. Later, when "endElement" is invoked, we have to remove them. |
@@ -1,7 +1,7 @@ |
||
| 1 | 1 | <?php |
| 2 | 2 | /** |
| 3 | - * Loads a string to be parsed. |
|
| 4 | - */ |
|
| 3 | + * Loads a string to be parsed. |
|
| 4 | + */ |
|
| 5 | 5 | namespace Masterminds\Html5\Parser; |
| 6 | 6 | |
| 7 | 7 | /* |
@@ -71,8 +71,9 @@ |
||
| 71 | 71 | public function __construct($data, $encoding = 'UTF-8', $debug = '') |
| 72 | 72 | { |
| 73 | 73 | $data = UTF8Utils::convertToUTF8($data, $encoding); |
| 74 | - if ($debug) |
|
| 75 | - fprintf(STDOUT, $debug, $data, strlen($data)); |
|
| 74 | + if ($debug) { |
|
| 75 | + fprintf(STDOUT, $debug, $data, strlen($data)); |
|
| 76 | + } |
|
| 76 | 77 | |
| 77 | 78 | // There is good reason to question whether it makes sense to |
| 78 | 79 | // do this here, since most of these checks are done during |
@@ -298,13 +298,9 @@ |
||
| 298 | 298 | $this->scanner->next(); // Consume the other '-' |
| 299 | 299 | $this->scanner->next(); // Next char. |
| 300 | 300 | return $this->comment(); |
| 301 | - } |
|
| 302 | - |
|
| 303 | - elseif ($tok == 'D' || $tok == 'd') { // Doctype |
|
| 301 | + } elseif ($tok == 'D' || $tok == 'd') { // Doctype |
|
| 304 | 302 | return $this->doctype(); |
| 305 | - } |
|
| 306 | - |
|
| 307 | - elseif ($tok == '[') { // CDATA section |
|
| 303 | + } elseif ($tok == '[') { // CDATA section |
|
| 308 | 304 | return $this->cdataSection(); |
| 309 | 305 | } |
| 310 | 306 | |
@@ -27,8 +27,8 @@ |
||
| 27 | 27 | |
| 28 | 28 | */ |
| 29 | 29 | /** |
| 30 | - * UTF-8 Utilities |
|
| 31 | - */ |
|
| 30 | + * UTF-8 Utilities |
|
| 31 | + */ |
|
| 32 | 32 | class UTF8Utils |
| 33 | 33 | { |
| 34 | 34 | |
@@ -1,13 +1,13 @@ |
||
| 1 | 1 | <?php |
| 2 | 2 | /** |
| 3 | - * @file |
|
| 4 | - * This contains HTML5 entities to use with serializing. |
|
| 5 | - * |
|
| 6 | - * The list here is mildly different from the list at \Masterminds\Html5\Entities because |
|
| 7 | - * that list was generated from the w3c. It contains some entities that are |
|
| 8 | - * not entirely proper such as &am; which maps to &. This list is meant to be |
|
| 9 | - * a fallback for PHP versions prior to PHP 5.4 when dealing with encoding. |
|
| 10 | - */ |
|
| 3 | + * @file |
|
| 4 | + * This contains HTML5 entities to use with serializing. |
|
| 5 | + * |
|
| 6 | + * The list here is mildly different from the list at \Masterminds\Html5\Entities because |
|
| 7 | + * that list was generated from the w3c. It contains some entities that are |
|
| 8 | + * not entirely proper such as &am; which maps to &. This list is meant to be |
|
| 9 | + * a fallback for PHP versions prior to PHP 5.4 when dealing with encoding. |
|
| 10 | + */ |
|
| 11 | 11 | namespace Masterminds\Html5\Serializer; |
| 12 | 12 | |
| 13 | 13 | /** |
@@ -1,11 +1,11 @@ |
||
| 1 | 1 | <?php |
| 2 | 2 | /** |
| 3 | - * @file |
|
| 4 | - * The rules for generating output in the serializer. |
|
| 5 | - * |
|
| 6 | - * These output rules are likely to generate output similar to the document that |
|
| 7 | - * was parsed. It is not intended to output exactly the document that was parsed. |
|
| 8 | - */ |
|
| 3 | + * @file |
|
| 4 | + * The rules for generating output in the serializer. |
|
| 5 | + * |
|
| 6 | + * These output rules are likely to generate output similar to the document that |
|
| 7 | + * was parsed. It is not intended to output exactly the document that was parsed. |
|
| 8 | + */ |
|
| 9 | 9 | namespace Masterminds\Html5\Serializer; |
| 10 | 10 | |
| 11 | 11 | use Masterminds\Html5\Elements; |
@@ -1,8 +1,8 @@ |
||
| 1 | 1 | <?php |
| 2 | 2 | /** |
| 3 | - * @file |
|
| 4 | - * The interface definition for Rules to generate output. |
|
| 5 | - */ |
|
| 3 | + * @file |
|
| 4 | + * The interface definition for Rules to generate output. |
|
| 5 | + */ |
|
| 6 | 6 | namespace Masterminds\Html5\Serializer; |
| 7 | 7 | |
| 8 | 8 | /** |