Navigation Menu

Skip to content

Commit

Permalink
Testing / minor basecode.
Browse files Browse the repository at this point in the history
  • Loading branch information
Gargaj committed Dec 15, 2013
0 parents commit 41a2fbf
Showing 1 changed file with 23 additions and 0 deletions.
23 changes: 23 additions & 0 deletions index.php
@@ -0,0 +1,23 @@
<?
require_once("config.inc.php");

require(POUETAPI_POUET_ROOT_LOCAL . "/bootstrap.inc.php");

function outputJSON( $object )
{
$out = json_encode( $object, JSON_PRETTY_PRINT );
if($_GET["callback"])
{
$callback = $_GET["callback"];
$out = $callback . "(" . $out . ")";
}
header("Content-type: application/json; charset=utf-8");
echo $out;
}

$prod = PouetProd::Spawn( $_GET["id"] ? $_GET["id"] : 1 );
$a = array(&$prod);
PouetCollectPlatforms( $a );

outputJSON( $prod );
?>

0 comments on commit 41a2fbf

Please sign in to comment.