Re: domxml in PHP5

From: Date: Thu, 10 Apr 2003 17:07:51 +0000
Subject: Re: domxml in PHP5
References: 1  Groups: php.xml.dev 
Request: Send a blank email to php-xml-dev+get-63@lists.php.net to get a copy of this message
On Thu, 2003-04-10 at 18:58, Marcus Börger wrote: > At 10:37 10.04.2003, Christian Stocker wrote: > >Hi > > > >It was very quiet on this list in recent weeks. > >[...] > >- use namespaces. Got already a patch from Tal for that. > > If you need any help ask me :-) I will ;) > >- use setters/getters. $domtext->data = "hello" should be possible with > >PHP5 (the properties in domxml at the moment are a joke and shouldn't > >be used..), this will allow much more dom-compliance > > Maybe we could have an own dowmxml object type with special handlers. > > >- Implement first most of the dom-standard. Then we add some of the > >convenience methods libxml2 has (get_content() et al. They are not in > >the dom-standard, but make the life for domxml-programmers a lot easier > >and they are also much faster than using the "traditional" dom methods) > > > >- Lastly, if there's time, add as much BC as possible. Or we just > >provide a PEAR-wrapper, which makes transition from domxml/PHP4.3 to > >domxml/PHP5 easier. > > > I disagree, domxml is experimental, so do not make the mistake to have > an incompatible version shipped with php5. Why must php always be > different? What do you mean with incompatible? Incompatible to PHP4 or incompatible to the DOM-Standard? I think now, maintaining BC for some of the more obscure domxml/4 stuff should be done in PHP-Userland (maybe a PEAR class) and not in domxml itself. This will allow much easier upgrading to PHP5 if you use domxml now. But domxml/5 should follow the Dom-Standard and not the domxml4-"standard". about get_content() and alike. These functions are very useful and faster than doing it the DOM-way. Of course, if you want to do it like the dom-standard wants it (looping through all your children and extract text-nodes instead of just call $node->get_content()), one should be able to do that. Therefore I said, first implement the DOM-Standard, then add those convenience method (which will not be much more than copy&paste from the current code) chregu > > marcus -- christian stocker | bitflux GmbH | schoeneggstrasse 5 | ch-8004 zurich phone +41 1 240 56 70 | mobile +41 76 561 88 60 | fax +41 1 240 56 71 http://www.bitflux.ch | chregu@bitflux.ch | gnupg-keyid 0x5CE1DECB

« previous php.xml.dev (#63) next »