(PHP 8 >= 8.4.0)
XMLReader::fromString — Creates an XMLReader from an XML string
public static XMLReader::fromString(string $source, ?string $encoding = null, int $flags = 0): static
Creates an XMLReader from an XML string.
Returns an XMLReader.
encoding will throw a ValueError.
© 1997–2025 The PHP Documentation Group
Licensed under the Creative Commons Attribution License v3.0 or later.
https://www.php.net/manual/en/xmlreader.fromstring.php