Re: WDDX recordset deserialize
Andrei:
If you agree with the variable structure returned, I could post the patch so we
do not have to see people doing string replacement before calling
wddx_deserialize().
On Thu, 8 Nov 2001, Andrei Zmievski wrote:
> On Thu, 08 Nov 2001, phillip@formstar.com wrote:
> > Hi all:
> >
> > I am thinking of a way to transform WDDX recordset element into PHP varialbles
> > when deserializing the packet.
> >
> > It seems that all recordset will look like:
> >
> > <var name="queryname"><recordset rowcount="?"
> > fieldname="f1,f2,...fn"><field
> > name="f1">...</field>...</recordset></var>
> >
> > The above can be transformed into:
> >
> > <var
> > name="queryname"><string>f1,f2,...fn</string></var><var
> > name="f1"><array>...</array></var><var
> > name="f2"><array>...</array></var>...
> >
> > If we parse as this transformation, in PHP script:
> >
> > $values = wddx_deserialize($packet);
> > $values["queryname"] = "f1,f2,...,fn";
> > $values["f1"] = values in array for "f1" field;
> > ....
> > $values["fn"] = values in array for "fn" field;
> >
> >
> > Should this solve the recordset problem?
>
> Deserializing the recordset is not a problem, but creating one out of
> PHP values is since there is no exact mapping. It would be better to
> have it work both ways, but maybe deserialization only support at this
> point is fine.
>
> -Andrei
>
> A room without books is like a body without a soul.
> -- Marcus Tullius Cicero (106-43 B.C.)
>
>
Phillip Pan
-----------
MD5 Fingerprint=0F:95:7B:D7:DE:D9:E0:EA:46:C0:2E:FD:EA:C4:25:0E
Thread (4 messages)