#45407 [Opn->WFx]: domxml function not documented

From: Date: Sat, 26 Jul 2008 11:25:02 +0000
Subject: #45407 [Opn->WFx]: domxml function not documented
References: 1  Groups: php.doc.bugs 
Request: Send a blank email to doc-bugs+get-1016@lists.php.net to get a copy of this message
ID: 45407 Updated by: bjori@php.net Reported By: cweismann at ea dot com -Status: Open +Status: Wont fix Bug Type: Documentation problem Operating System: Linux PHP Version: 4.3.2 New Comment: I really doubt anyone will be document PHP4 specific features :| PHP4 support was discontinued over 6months ago and I see no reason to put any effort in documenting it. Previous Comments: ------------------------------------------------------------------------ [2008-07-10 14:02:55] cweismann at ea dot com corrected version number ------------------------------------------------------------------------ [2008-07-01 17:51:37] cweismann at ea dot com Description: ------------ I ran into problems with the memory leak with domxml. I am working on a very old and very large website and am unable to upgrade to PHP5 until I have converted all of the old code, so I am writing my code to be compatible with both PHP4.3.2 and PHP5. After much searching, I located a bug report at http://bugs.php.net/bug.php?id=30911&edit=1 that mentioned $doc->free(), but I could not find any documentation for this function. I later found a very good description in the below post on http://us2.php.net/domxml-open-mem. This fixed the problem, but it would make life easier for other people with the same problem if the $doc->free(); function was documented. ej at campbell *dot* name 30-Nov-2003 07:54 <!-- quote --> The DOM XML parser does not automatically free memory when a DomDocument goes out of scope. If you're using the DOM parser to parse several XML files as part of a long running script, you must free the DomDocument manually or a memory leak will occur. To free a DOM document allocated by domxml_open_mem, do the following: $doc = domxml_open_mem("$contents"); $doc->free(); <!-- end quote --> ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=45407&edit=1

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