* @copyright Australian Consortium for Social and Political Research Inc (2011) * @package queXS * @subpackage admin * @link http://www.acspri.org.au/ queXS was writen for ACSPRI * @license http://opensource.org/licenses/gpl-2.0.php The GNU General Public License (GPL) Version 2 * * */ /** * Configuration file */ include("../config.inc.php"); /** * Database file */ include ("../db.inc.php"); /** * Authentication file */ require ("auth-admin.php"); /** * XHTML functions */ include("../functions/functions.xhtml.php"); /** * Display functions */ include("../functions/functions.display.php"); /** * Input functions */ include("../functions/functions.input.php"); /** * Limesurvey functions */ include("../functions/functions.limesurvey.php"); $css = array( "../include/bootstrap/css/bootstrap.min.css", "../css/custom.css" ); $js_head = array( ); $js_foot = array( "../js/window.js", "../js/custom.js" ); global $db; xhtml_head(T_("Questionnaire services"),true,$css,$js_head);//array("../css/table.css"),array("../js/window.js") $error = false; if (isset($_POST['description'])) { $test = limerpc_init($_POST['rpc_url'],$_POST['username'],$_POST['password']); if ($test === true) { $description = $db->qstr($_POST['description']); $rpc_url = $db->qstr($_POST['rpc_url']); $username = $db->qstr($_POST['username']); $password = $db->qstr($_POST['password']); $entry_url = $db->qstr($_POST['entry_url']); $sql = "INSERT INTO `remote` (description,rpc_url,username,password,entry_url) VALUES ($description,$rpc_url,$username,$password,$entry_url)"; $db->Execute($sql); } else { $error = $test; } } //view groups $sql = "SELECT id, rpc_url, username, description, CONCAT('". TQ_("Modify") . "') as link FROM remote"; $rs = $db->GetAll($sql); print "