Follow

Integrating the Servasport JSON Feed (NEW)

If there are any questions about the following information or examples are needed, please contact Servasport: GAA Support.

An Example

An Example of the JSON feed can be found at: 

http://people.gaa.ie/fixtures/json/demo/

 

The Code

Insert the following lines of code into the head of your HTML document:

 

<script type="text/javascript" src="http://code.jquery.com/jquery-1.7.2.min.js"></script>
<script type="text/javascript">var baseParam='[ENTER PARAMETERS HERE]';var onLoadParam = '[ENTER PARAMETERS HERE]';var navParam = '[ENTER PARAMETERS HERE]';var colour = '2488CE';</script>
<script type="text/javascript" src="http://people.gaa.ie/fixtures/json/javascript/fixtures.min.js"></script>

An example of parameters would be:

var baseParam='clubID=####';

var onLoadParam = 'daysAfter=7';

var navParam = 'clubID=#';

 

Insert the following line of code into the area where you want your feed:

<div id="fixtureContent"></div>

 

The Parameters

Any of the following parameters can be added into the second line of code in the 'params' variable before the var colour statement:

 

  • clubID=1234: Get all fixtures and results for club 1234
  • compID=1234: Get all fixtures and results for competition 1234
  • venueID=1234: Get all fixtures and results for venue 1234
  • compGroupID=1234: Get all fixtures and results for competitions that are part of competitionGroup 1234
  • fixturesOnly=: Y/N Only return fixtures
  • resultsOnly=: Y/N Only return results
  • countyBoardID=1234: Get all fixtures for clubs from County Board 1234
  • includeCountyGames=: Y/N Include fixtures that the County is participating in.(always defaulted to Y when it's not included)
  • includeProvincialGames-: Y/N Include fixtures that the province is participating in.(always defaulted to Y when it's not included)
  • includeClubGames-: Y/N Include fixtures that clubs are participating in.(always defaulted to Y when it's not included)
  • provinceName=: Ulster/Munster/Leinster/Connacht/Britain/Europe/North America Get all fixtures for clubs in the province specified.
  • leagueTable=Y/N: Generate League Table XML if Y (must be used in conjunction with compID)
  • daysPrevious=X: Gets results for the previous X days (ignores fix/results filter mutually exclusive with daysAfter)NOTE:This is up to a Max of 15 days
  • daysAfter=X: Gets fixtures for next X days (ignores fix/results filter - mutually exclusive with daysPrevious)NOTE:This is up to a Max of 15 days
  • dateFrom=20091230: Gets fixtures/results from date 2009/12/30 combined with dateTo (ignores fix/results filter)
  • dateTo=20091230: Gets fixtures/results from date 2009/12/30 combined with dateFrom (ignores fix/results filter)
  • owner=1234: Gets all of the fixtures that a county owns, plus all of the fixtures that county is participating in.
  • compStyle=: football/hurling Only return specified type of fixtures
  • reverseDateOrder=Y/N: Reverse the Order of the fixtures based on date.
  • noTBC=Y: Add this parameter to not show TBC fixtures
  • orderTBCLast=Y: Add this parameter to show the TBC fixtures at the bottom of this list.
  • gender: Add this parameter to the list with no value and it will pull out female fixtures only.
  • showArchive=Y: If your site has an archive section, this parameter is needed to display the historical results, as by default the feed will not return these results.
  • season=: For searching historical results use this parameter with the above parameter (showArchive) to retrieve all results from a certain season.
  • compLevel:=(Senior, Intermediate...) get all the fixtures/results for that Level
  • compAgeLevel:=(Senior, U21, U20...) get all fixtures/results for that age level
  • uniqueID=42415: Get the result/Fixture for the specific game
  • includeCollegeGames:= Y/N Include fixtures that the College is participating in.(always defaulted to Y when it's not included)
  • includeSchoolGames:= Y/N Include fixtures that the School is participating in.(always defaulted to Y when it's not included)
  • leagueTableOnly:= Y/N Returns a League table with no fixtures or results (Must be used in conjunction with a CompID or CompGroupID

 

If you want to change the colours instead of grey (555555), just simply change the two colour references in the second line. For example, if we want to change the colour to blue (0065CC).
Note - Colours are in Hexadecimal format

 

<script type="text/javascript">var params='countyBoardID=1234&orderTBCLast=Y&colour=0065CC';var colour = '0065CC';</script>

Was this article helpful?
0 out of 0 found this helpful
Have more questions? Submit a request

Comments