Here is a short snippet to pass data from PHP to JavaScript:

If you liked this, please share this on Facebook, Twitter or Google+.