Exemplo n.º 1
0
function DBChiefRunGiveUp($number, $site, $contest)
{
    return DBRunGiveUp($number, $site, $contest, -1, -1);
}
Exemplo n.º 2
0
//    the Free Software Foundation, either version 3 of the License, or
//    (at your option) any later version.
//
//    This program is distributed in the hope that it will be useful,
//    but WITHOUT ANY WARRANTY; without even the implied warranty of
//    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
//    GNU General Public License for more details.
//    You should have received a copy of the GNU General Public License
//    along with this program.  If not, see <http://www.gnu.org/licenses/>.
////////////////////////////////////////////////////////////////////////////////
// Last modified 21/jul/2012 by cassio@ime.usp.br
require 'header.php';
if (isset($_POST["answer"]) && isset($_POST["giveup"]) && $_POST["giveup"] == "Cancel editing" && isset($_POST["sitenumber"]) && isset($_POST["number"]) && is_numeric($_POST["number"]) && is_numeric($_POST["sitenumber"])) {
    $sitenumber = myhtmlspecialchars($_POST["sitenumber"]);
    $number = myhtmlspecialchars($_POST["number"]);
    DBRunGiveUp($_POST["number"], $_POST["sitenumber"], $_SESSION["usertable"]["contestnumber"], $_SESSION["usertable"]["usernumber"], $_SESSION["usertable"]["usersitenumber"]);
    MSGError("Run returned.");
    ForceLoad("run.php");
}
if (isset($_POST["answer"]) && isset($_POST["Submit"]) && $_POST["Submit"] == "Judge" && is_numeric($_POST["answer"]) && isset($_POST["sitenumber"]) && isset($_POST["number"]) && is_numeric($_POST["sitenumber"]) && is_numeric($_POST["number"])) {
    // && isset($_POST["notifyuser"]) && isset($_POST["updatescore"])) {
    if ($_POST["confirmation"] == "confirm") {
        $answer = myhtmlspecialchars($_POST["answer"]);
        $sitenumber = myhtmlspecialchars($_POST["sitenumber"]);
        $number = myhtmlspecialchars($_POST["number"]);
        //      	  $notuser = myhtmlspecialchars($_POST["notifyuser"]);
        //	        $updscore = myhtmlspecialchars($_POST["updatescore"]);
        DBUpdateRun($_SESSION["usertable"]["contestnumber"], $_SESSION["usertable"]["usersitenumber"], $_SESSION["usertable"]["usernumber"], $sitenumber, $number, $answer);
        //, $notuser, $updscore);
    }
    ForceLoad("run.php");