$dir = getcwd(); try { define("IN_MYBB", 1); chdir('forums'); // path to MyBB include './global.php'; $uid = $mybb->user['uid']; $user = $mybb->user['username']; } catch (Exception $e) { } chdir($dir); } foreach ($urls as $index => $url) { $url = trim($url); if (strlen($url)) { $id = SubmitTest($url, $labels[$index]); if ($id && strlen($id)) { $ids[] = $id; } } } // now add the industry urls foreach ($_REQUEST['t'] as $tid) { $tid = trim($tid); if (strlen($tid)) { $ids[] = $tid; } } // if we were successful, redirect to the result page if (count($ids)) { $idStr = '';
$ids = array(); $ip = $_SERVER['REMOTE_ADDR']; $key = ''; $keys = parse_ini_file('./settings/keys.ini', true); if ($keys && isset($keys['server']) && isset($keys['server']['key'])) { $key = trim($keys['server']['key']); } $headless = false; if (array_key_exists('headless', $settings) && $settings['headless']) { $headless = true; } if (!$headless) { foreach ($urls as $index => $url) { $url = trim($url); if (strlen($url)) { $id = SubmitTest($url, $labels[$index], $key); if ($id && strlen($id)) { $ids[] = $id; } } } // now add the industry urls foreach ($_REQUEST['t'] as $tid) { $tid = trim($tid); if (strlen($tid)) { $ids[] = $tid; } } } // if we were successful, redirect to the result page if (count($ids)) {
<?php /** * Created by JetBrains PhpStorm. * User: microsoftLT * Date: 4/9/14 * Time: 8:59 AM * To change this template use File | Settings | File Templates. */ include "RedirectNotSession.php"; include "dbconnect.php"; if (isset($_POST['start']) && isset($_POST['stop']) && isset($_POST['step']) && isset($_POST['benchmark']) && isset($_SESSION['userid'])) { $resultid = SubmitTest($_SESSION['userid']); if (isset($resultid)) { //echo $resultid; $output = $resultid . '$' . 'gtx-770$' . $_POST['benchmark'] . '$' . $_POST['start'] . "\$" . $_POST['stop'] . "\$" . $_POST['step'] . "\$"; exec("java -jar Client.jar " . $output); //exec("java -jar C:/wamp/www/FYP/INTELLClient.jar", $output); header("location: confirm.php"); } } include "header.php"; echo ' <div id="contentWrapper"> <div id=""> <div class="container"> <!-- #Features --> <div class="" style="margin: 20px;padding: 20px;"> <form action="submittest.php" method="post"> <div> <select name="benchmark">