Jump to content

Insert PHP output into JS variable.


kirill578

Recommended Posts

In short, what you're talking about is what AJAX is:  Asynchronous Javascript and XML.

While it originally took XML from (usually) php output and worked with it on the javascript side, the term AJAX incorporates all types of returned data, including html, text, JSON, and JSONP. 

 

What was used in the above example was jQuery, a javascript framework that makes a lot of javascript, but especially AJAX pathetically easy to write and work with.  I was fumbling all over trying to learn javascript in order to do AJAX, but jQuery got me up and writing code practically overnight. 

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.