xmlwriter_start_document()
function xmlwriter_start_document(mixed $writer, ?string $version = '1.0', ?string $encoding = null, ?string $standalone = null): bool
Writes the XML declaration.
Parameters:
$writer(mixed)$version(?string), default'1.0', optional$encoding(?string), defaultnull, optional$standalone(?string), defaultnull, optional
Returns: bool
Availability
- Compiled (AOT): supported through an injected elephc-PHP prelude.
eval()(magician interpreter): supported — declarative interpreter builtin (crates/elephc-magician/src/interpreter/builtins/xml/xmlwriter_start_document.rs).
No examples yet — check examples/ and showcases/ for usage patterns.
Internals
For how xmlwriter_start_document is implemented in the compiler, see the internals page.