cURL / Mailing Lists / curl-and-php / Single Mail

curl-and-php

Re: Using Curl to Fetch Javascript DataTable Info

From: Daniel Stenberg <daniel_at_haxx.se>
Date: Sat, 21 Feb 2009 22:07:13 +0100 (CET)

On Sat, 21 Feb 2009, Ben Niebel wrote:

> More recently, I've been trying to accomplish the same task for some minor
> league baseball teams from milb.com. This process had not been nearly as
> easy because MILB displays their rosters in dynamic JavaScript DataTables
> (see http://web.minorleaguebaseball.com/milb/stats/stats.jsp?t=t_ros&cid=452
> ).
>
> Does anybody have any tips on how I might be able to use PHP/Curl to fetch
> the player information stored in these tables?

Sure! Run a manual session with Firefox and record it all with
LiveHTTPHeaders. Then replay those requests using curl requests instead.

This and other useful hints could be found here:

         http://curl.haxx.se/docs/httpscripting.html

-- 
  / daniel.haxx.se
_______________________________________________
http://cool.haxx.se/cgi-bin/mailman/listinfo/curl-and-php
Received on 2009-02-21