Eric <lefauv...@gmail.com> wrote:
> The easiest way to do that is to build a PHP array, and to use
> JSON_Encode to convert it into a JSON encoded string;
Yes, that's the right way.
If you aim for an associative array you should however watch out for a
particular gotcha: If such an array has members, it will turn into a
in a blue moon the associative PHP array happens to be empty, then you
supposed object, you'll get a nasty surprise. So always check if your
object is really an object. (I was bitten by this on several
occasions, and it hurt.)
You received this message because you are subscribed to the Google Groups
"Prototype & script.aculo.us" group.
To post to this group, send email to email@example.com.
To unsubscribe from this group, send email to
For more options, visit this group at