Re: [PHP-XML-DEV] [domxml] namespaces / exception / extensionname
[email protected] (Shane Caraveo)
| Newsgroups | php.xml.dev |
|---|---|
| Message-ID | <[email protected]> |
Christian Stocker wrote: > Hi > > >>It would be nice if this was developed as a dual pupose extension, for >>php4.x and php5. Then being put into pecl, people could dowload this >>and have an improved domxml for installations that wont update to php 5 >>for some time. I think extension development needs to stop being >>focused on the next release, and start focusing on supporting what is >>out there. 4.3.x will be in use for a long time before the majority >>switch to php5. > > > If we use namespaces and exceptions, it will be hard to maintain php4 and > php5 compatiblity.. But maybe it can be solved with some #ifdefs ;) The > only problem being, that code written for php4 is not compatible with code > written for php5 (in php4 it wold be domxml_domimplementation, in php5 > domxml::domimplementation for example) The code differences are fine. Stepping between 4.x and 5 is going to break things anyway, as far as I'm concerned, and the change is simple enough to deal with in most cases. It's also simple enough to write little script wrappers to add compatibility. I just think it's important for extensions to start being developed 'independent of the engine', so that updates to extensions can benefit more than just the next release. > >>Also, are function names going to follow the standard or are they being >>phpized? (getElementById or get_element_by_id) Again, I think the DOM >>standard should be followed, and not php's standard. > > > Didn't think about that. Both have their advantages and disadvantages > > >>>- Extension Name: It looks like domxml5 will be more or less completely > > [...] > >>use a new name....xmldom, libxml, or just plain dom. > > > nothing with dom,please ;) ext/libxml would be ok, since it's based on > libxml2, but I don't like it that much .. ext/xml would be ideal, but this > is taken and I don't think, we can break the API of that, as well ;) > > chregu Well, in the long run, PEAR should provide a wrapping mechanism, similar to PyXML, which allows transparent usage of different XML engines. It's a good thing to have multiple C implementations in different namespaces. BTW, does libxml have a streaming pull parser? Shane