First that all sorry for my english :)

im not 100% sure but remember that ? not is a valid character... you
need to encode your data before submit your JSON

I you are using POST method not is obvius but think in GET

On 24 jun, 15:04, maalek <maaa...@gmail.com> wrote:
> Hi,
>
> I build webapp with lots use AJAX via Prototype.I have problem with
> Object.toJSON function.
>
> simple example from Prototype APIhttp://www.prototypejs.org/api/object/toJSON
>
> var test = {name: 'Violet', occupation: 'character', age: 25, pets:
> ['frog', 'rabbit']};
> Object.toJSON(test);
> --- > {"name": "Violet", "occupation": "character", "age": 25, "pets":
> ["frog", "rabbit"]}
>
> OK
>
> but
>
> var test = {name: 'Violet ? Blue', occupation: 'character', age: 25,
> pets: ['frog', 'rabbit']};
> Object.toJSON(test);
> --- > Blue", "occupation": "character", "age": 25, "pets": ["frog",
> "rabbit"]}
>
> truncate from test.name all before ? (question mark)
>
> Can anybody help me??

--~--~---------~--~----~------------~-------~--~----~
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 prototype-scriptaculous@googlegroups.com
To unsubscribe from this group, send email to 
prototype-scriptaculous+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/prototype-scriptaculous?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to