<?php /**/ ?><?php
/*
Sudoku Puzzle generator
(C) Copyright 2007-2016
John Ryland <jryland@invertedlogic.com>
ALL RIGHTS RESERVED
*/
$argsStr = $_GET['game_id'] . ' ' . $_GET['type'] . ' ' . $_GET['difficulty'] . ' ' . $_GET['id'];
$args = explode(' ', trim($argsStr));
$escapedArgs = array();
foreach ($args as $arg) {
$escapedArgs[] = escapeshellarg($arg);
}
$argsStr = implode(" ", $escapedArgs);
sleep(1);
$tmp = exec("./sudoku " . $argsStr, $possibles);
echo implode("\n", $possibles);
echo "\n";
?>