I'm using cURL to access a site. The problem is that content that I need to grab is generated by a script as:
function Button(){
...
document.getElementById("out").innerHTML = name;
}
<p id="out"></p>
With cURL, I have the code of the page but not the content. I'm using this config:
$curl = curl_init();
curl_setopt($curl, CURLOPT_URL, $url);
curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($curl, CURLOPT_REFERER, $referer);
curl_setopt($curl, CURLOPT_COOKIEFILE, $cookiefile);
$redirects=5000;
$data = curl_redirect_exec($curl,$redirects);
curl_close($curl);
I could get the content generate by the script.