Re: Re: XML_Serializer - flexible node attributes?
| From: | Guillaume Lecanu | Date: | Mon, 19 Dec 2005 08:33:38 +0000 |
| Subject: | Re: Re: XML_Serializer - flexible node attributes? | ||
| References: | 1 2 3 4 | Groups: | php.pear.general |
| Request: | Send a blank email to pear-general+get-22302@lists.php.net to get a copy of this message | ||
Oops sorry, I have misunderstand your problem, I have understand you
want adapt XML_Serializer to uses XML_FastCreate (XFC) !
So, if you want to make a XML Document, XFC is a good way :)
Le lundi 19 décembre 2005 à 09:26 +0100, Guillaume Lecanu a écrit :
> Le vendredi 16 décembre 2005 à 15:26 -0500, Andrew Nagy a écrit :
>
> > Andrew Nagy wrote:
> > > Stephen Musgrave wrote:
> > >
> > >> Someone had responded to the thread, explaining that they should use
> > >> XML_FastCreate instead.
> > >
> > >
> > > Yes, I am in the process of switching my XML_Serializer object over to
> > > an XML_FastCreate because I don't think there is anyway to have multiple
> > > elements at one level with the same name due to the nature of
> > > associative arrays.
> > >
> > > It looks like XML_FastCreate can accomplish what you need to do.
> >
> > Scratch that idea, I am sticking with XML_Serializer. XML_FastCreate
> > will not allow the use of ':' in an element name (commonly used with
> > namespaces) due to the nature of object variables.
>
> I'm the author of XML_FastCreate, this package could make tags with ':'
> but you need to used the xml() method instead to uses the overloading
> system :
> $x->xml('like:this', params...)
>
> But I think XML_FastCreate is not the good way for you, I think it's a
> good tool for end-developper, but I think it's not a good way for other
> packages because this will take too memory / time rather a native
> methods of PHP (uses DOM XML of PHP5)
>
>
> >
> > Also, I figured out how to allow multiple elements at one level with the
> > same name. You can set everything in a subarray and use the "simplexml"
> > option.
> >
> > Andrew
> >