|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #38578 Can't create internal entities
Submitted: 2006-08-24 10:23 UTC Modified: 2006-08-24 11:40 UTC
From: dandrikop at cosmote dot gr Assigned:
Status: Not a bug Package: DOM XML related
PHP Version: 5.1.5 OS: Fedora Core 5
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
Block user comment
Status: Assign to:
Bug Type:
From: dandrikop at cosmote dot gr
New email:
PHP Version: OS:


 [2006-08-24 10:23 UTC] dandrikop at cosmote dot gr
Cannot create internal entity declarations with DOMImplementation object like the following:

<!DOCTYPE clickAPI SYSTEM "my.dtd" [
    <!ENTITY testme "HELLO">


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2006-08-24 10:25 UTC]
Not enough information was provided for us to be able
to handle this bug. Please re-read the instructions at

If you can provide more information, feel free to add it
to this bug and change the status back to "Open".

Thank you for your interest in PHP.

 [2006-08-24 11:05 UTC] dandrikop at cosmote dot gr
As the documentation says at "" the following code:


// Creates an instance of the DOMImplementation class
$imp = new DOMImplementation;

// Creates a DOMDocumentType instance
$dtd = $imp->createDocumentType('graph', '', 'graph.dtd');

// Creates a DOMDocument instance
$dom = $imp->createDocument("", "", $dtd);

// Set other properties
$dom->encoding = 'UTF-8';
$dom->standalone = false;

// Create an empty element
$element = $dom->createElement('graph');

// Append the element

// Retrieve and print the document
echo $dom->saveXML();


<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!DOCTYPE graph SYSTEM "graph.dtd">

So how can someone produce the following XML?

<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!DOCTYPE graph SYSTEM "graph.dtd"[
    <!ENTITY testme "HELLO">
 [2006-08-24 11:40 UTC]
Sorry, but your problem does not imply a bug in PHP itself.  For a
list of more appropriate places to ask for help using PHP, please
visit as this bug system is not the
appropriate forum for asking support questions.  Due to the volume
of reports we can not explain in detail here why your report is not
a bug.  The support channels will be able to provide an explanation
for you.

Thank you for your interest in PHP.

PHP Copyright © 2001-2020 The PHP Group
All rights reserved.
Last updated: Fri Dec 04 02:01:23 2020 UTC