I'm using ajax to request data and and echoing a string containing a number of variables and trying to parse this data using javascript.
Echo eg. fullname=Joe Soap&companyname=banana&website=mywebsite.com
In my javascript, I understand I could use string functions to search and extract, but this seems a bit cumbersome.
I'm assuming there is a much more elegant solution which I don't know about (I haven't been coding in PHP and javascript for very long) and I'm keen to learn the best practices.
What is the best way to achieve this?
- Is this the best way to echo multiple values back to my javascript? 
- What is the best way in javascript to parse the data? 
Thanks in advance.
 
     
    