Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>Disclaimer: I'm the author of the tools I'm about to promote.</p> <p>Over the past year, I've written a couple Python libraries that will do what you want. The first is <a href="https://github.com/BurntSushi/nflgame" rel="noreferrer">nflgame</a>, which gathers game data (including play-by-play) from NFL.com's GameCenter JSON feed. This includes active games where data is updated roughly every 15 seconds. nflgame <a href="https://github.com/BurntSushi/nflgame/wiki" rel="noreferrer">has a wiki</a> with some tips on getting started.</p> <p>I released nflgame last year, and used it throughout last season. I think it is reasonably stable.</p> <p>Over this past summer, I've worked on its more mature brother, <a href="https://github.com/BurntSushi/nfldb" rel="noreferrer">nfldb</a>. nfldb provides access to the same kind of data nflgame does, except it keeps everything stored in a relational database. nfldb <a href="https://github.com/BurntSushi/nfldb/wiki" rel="noreferrer">also has a wiki</a>, although it isn't entirely complete yet.</p> <p>For example, this will output all current games and their scores:</p> <pre><code>import nfldb db = nfldb.connect() phase, year, week = nfldb.current(db) q = nfldb.Query(db).game(season_year=year, season_type=phase, week=week) for g in q.as_games(): print '%s (%d) at %s (%d)' % (g.home_team, g.home_score, g.away_team, g.away_score) </code></pre> <p>Since no games are being played, that outputs all games for next week with <code>0</code> scores. This is the output with <code>week=1</code>: (of the 2013 season)</p> <pre><code>CLE (10) at MIA (23) DET (34) at MIN (24) NYJ (18) at TB (17) BUF (21) at NE (23) SD (28) at HOU (31) STL (27) at ARI (24) SF (34) at GB (28) DAL (36) at NYG (31) WAS (27) at PHI (33) DEN (49) at BAL (27) CHI (24) at CIN (21) IND (21) at OAK (17) JAC (2) at KC (28) PIT (9) at TEN (16) NO (23) at ATL (17) CAR (7) at SEA (12) </code></pre> <p>Both are licensed under the WTFPL and are free to use for any purpose.</p> <p>N.B. I realized you tagged this as PHP, but perhaps this will point you in the right direction. In particular, you could use <code>nfldb</code> to maintain a PostgreSQL database and query it with your PHP program.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload