# Very difficult javascript/Ajax extraction using PHP

**URL:** <https://forum.kirupa.com/t/very-difficult-javascript-ajax-extraction-using-php/263288>\
**Category:** programming\
**Created:** [June 14, 2008, 2:19am UTC](https://forum.kirupa.com/t/very-difficult-javascript-ajax-extraction-using-php/263288 "2008-06-14T02:19:53Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![dinchu37](https://avatars.discourse-cdn.com/v4/letter/d/c57346/32.png) [@dinchu37](https://forum.kirupa.com/u/dinchu37)\
**Post date:** [June 14, 2008, 2:19am UTC](https://forum.kirupa.com/t/very-difficult-javascript-ajax-extraction-using-php/263288/1 "2008-06-14T02:19:53Z")

</div>

Hi, i need to make a web aplication that is able to get the contents from a webpage, the problem is almost the entire website is in ajax and i need to get an specific data and the only way to access there is inserting a javascript command.

The traditional way is to copy the webpage contents but i need to copy them after the ajax loads the info i’m looking for.

Please Help me!

I’m using javascript, php and curl is possible to make something to get that info?

---

<div class="post-metadata">

**Author:** ![Templarian](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/templarian/32/7152_2.png) [@Templarian](https://forum.kirupa.com/u/Templarian)\
**Post date:** [June 14, 2008, 3:22am UTC](https://forum.kirupa.com/t/very-difficult-javascript-ajax-extraction-using-php/263288/2 "2008-06-14T03:22:01Z")

</div>

Why exactly can’t you get the data directly from where their javascript gets it from? If they are accessing a php file go directly to that part in their source and grab the data with php (JS, may have security things grabbing stuff from another domain in that way).

---

<div class="post-metadata">

**Author:** ![dinchu37](https://avatars.discourse-cdn.com/v4/letter/d/c57346/32.png) [@dinchu37](https://forum.kirupa.com/u/dinchu37)\
**Post date:** [June 14, 2008, 3:47am UTC](https://forum.kirupa.com/t/very-difficult-javascript-ajax-extraction-using-php/263288/3 "2008-06-14T03:47:32Z")

</div>

the site is [betfair.com](http://betfair.com), is using java not php
