lundi 22 août 2016

How to get Javascript variable from an HTML page?

In the source code of a page on the internet, there is a Javascript variable containing JSON data that I would like to store in a variable in my PHP program.

Any idea about how to do it?

The file is on a public html link and it looks like this:

<script type="text/javascript">
    var serializedForm = {"fields": ... } ;
</script>

Thank you for your time and answers :).

Aucun commentaire:

Enregistrer un commentaire