[jQuery] Re: What is the best way to send data betwen JS - PHP

2008-06-20 Thread Konstantin Tokar
but sometimes text contains \ or another istrange characters and not like to be correct send data in this way. ¿what is the best way? PHP - JS I use json, but for JS-PHP? JSON!!! function KT_RPC(subname, data, on_success, on_error){ jQuery.ajax({ 'type': POST, 'url':

[jQuery] Re: What is the best way to send data betwen JS - PHP

2008-06-19 Thread mmw
Use a Json serialization script.php?request=s:e:r:i:a:l:i:z:a:t:i:o:n only one parameter by script, then you parse the request it's called RPC, as well as the question the answer (if needed) should have the same shape it's also called IPC at kernel level, you can also use url_encode... Cheers!

[jQuery] Re: What is the best way to send data betwen JS - PHP

2008-06-19 Thread Isaak Malik
There isn't really a best method, but if you're using GET then you should always convert your special characters to URI safe characters using: encodeURIComponent(). For sensitive data it's better to use POST. On Thu, Jun 19, 2008 at 12:51 PM, Aaron [EMAIL PROTECTED] wrote: Hi, I use POST for