-I have read about json being a simple way but also read its a bad practice to use eval() once the data is retrieved. So I don't know how so use the data returned.
-The only way i've been able to retrieve data from php scripts is if I echo the results already formatted (which is not very convenient). Also if there is a redirect in the php script the whole redirected pages html gets passed back to javascript.
Can somebody please recommend a way to send variables or arrays back to javascript from php?