Doc #79341 [PATCH]: XmlWriter docs does not say $uri is nullable

From: Date: Wed, 04 Mar 2020 12:51:37 +0000
Subject: Doc #79341 [PATCH]: XmlWriter docs does not say $uri is nullable
References: 1  Groups: php.doc.bugs 
Request: Send a blank email to doc-bugs+get-17360@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=79341&edit=1 ID: 79341 Patch added by: cmb@php.net Reported by: jtojnar at gmail dot com Summary: XmlWriter docs does not say $uri is nullable Status: Open Type: Documentation Problem Package: XML Writer PHP Version: Irrelevant Block user comment: N Private report: N New Comment: The following pull request has been associated: Patch Name: Fix #79341: XmlWriter docs does not say $uri is nullable On GitHub: https://github.com/php/doc-en/pull/54 Patch: https://github.com/php/doc-en/pull/54.patch Previous Comments: ------------------------------------------------------------------------ [2020-03-04 10:31:25] jtojnar at gmail dot com Description: ------------ --- From manual pages: * https://php.net/function.xmlwriter-write-attribute-ns * https://www.php.net/manual/en/function.xmlwriter-write-element-ns.php --- The URI element should be marked as nullable, see the stub: https://github.com/php/php-src/blob/c05a9c3dcd587418906d9d25f83872e027f7dd43/ext/xmlwriter/xmlwriter.stub.php#L35 Test script: --------------- <?php $writer = new XMLWriter; $writer->openMemory(); $writer->setIndent(true); $writer->startElement('foo'); $writer->writeAttribute('xmlns:example', 'https://www.example.com/'); $writer->startElementNS('example', 'meta', null); $writer->writeAttributeNS('example', 'spout', null, 'test'); $writer->endElement(); $writer->endElement(); echo $writer->outputMemory(); ------------------------------------------------------------------------ -- Edit this bug report at https://bugs.php.net/bug.php?id=79341&edit=1

« previous php.doc.bugs (#17360) next »