getAsciiAlphaNum example

$this->scanner->unconsume(2);

                    return '&';
                }
                $entity = CharacterReference::lookupDecimal($numeric);
            }
        } elseif ('=' === $tok && $inAttribute) {
            return '&';
        } else { // String entity.             // Attempt to consume a string up to a ';'.             // [a-zA-Z0-9]+;             $cname = $this->scanner->getAsciiAlphaNum();
            $entity = CharacterReference::lookupName($cname);

            // When no entity is found provide the name of the unmatched string             // and continue on as the & is not part of an entity. The & will             // be converted to & elsewhere.             if (null === $entity) {
                if (!$inAttribute || '' === $cname) {
                    $this->parseError("No match in entity table for '%s'", $cname);
                }
                $this->scanner->unconsume($this->scanner->position() - $start);

                
Home | Imprint | This part of the site doesn't use cookies.