Re: PHP-GTK2 docs

From: Date: Thu, 10 Feb 2005 21:09:48 +0000
Subject: Re: PHP-GTK2 docs
References: 1 2 3 4 5 6 7 8 9 10 11 12 13  Groups: php.gtk.doc 
Request: Send a blank email to php-gtk-doc+get-1285@lists.php.net to get a copy of this message
Sorry if this gets sent twice. I had some Mozilla problems. Christian Weiske wrote:
IMHO this would be safe. But if somebody would use the cdata things in a different position, it would be useless.
Can you think of an example where some one would need to do this? I ran this on the gtk directory: grep -B 1 '<!\[CDATA\[' * And <![CDATA[ only after programmlisting and one time after <command>. Also, every entry for program listing or command was followed by <![CDATA[. I think we can safely say that adding a cdata marker automatically after program listing will not cause too many problems.
Is it the php5 xml which removes this? Is there a pear xml package which recognizes and respects the cdata tags?
From what I can find, the xml_parse function never made a distinction between the two and still doesn't. The DOMXML extension does (except as of PHP 4.3.10+) let the user know if there was a <![CDATA[ marker but that is a PECL extension that needs to be compiled specially. I can't imagine that a whole lot of people are going to be building the docs on their own but I think they should be able to do it without having to install a seperate PEAR package. Besides, PEAR::XML_Parser uses xml_parse() so, unless they do something funny, I think the same thing will happen.
If not, couldn't you simply get the text (line + col) position and insert the plain xml in the plain xml file without using a tree? So that you don't use the xml functions just do good old "substr + new tags + substr"?
I guess, but that sounds like it won't be much fun to implement. I'll also loose some of the validation features that you get with the XML functions. Thanks, Scott

« previous php.gtk.doc (#1285) next »