function __construct() { $GLOBALS['phpgw_info']['flags']['noframework'] = true; require_once PHPGW_SERVER_ROOT . '/felamimail/inc/xajax.inc.php'; $xajax = new xajax($GLOBALS['phpgw']->link('/felamimail/xajax.php', false, true), 'xajax_', 'utf-8'); $xajax->waitCursorOff(); $xajax->registerFunction("doXMLHTTP"); $GLOBALS['phpgw_info']['flags']['java_script'] .= $xajax->getJavascript($GLOBALS['phpgw_info']['server']['webserver_url'] . '/felamimail/js/'); $GLOBALS['phpgw']->js->validate_file('jsapi', 'jsapi', 'felamimail'); $this->displayCharset = 'utf-8'; if (!isset($_POST['composeid']) && !isset($_GET['composeid'])) { // create new compose session $this->bocompose = CreateObject('felamimail.bocompose', '', $this->displayCharset); $this->composeID = $this->bocompose->getComposeID(); } else { // reuse existing compose session if (isset($_POST['composeid'])) { $this->composeID = $_POST['composeid']; } else { $this->composeID = $_GET['composeid']; } $this->bocompose = CreateObject('felamimail.bocompose', $this->composeID, $this->displayCharset); } $this->t = CreateObject('phpgwapi.Template', PHPGW_APP_TPL); $this->bofelamimail = CreateObject('felamimail.bofelamimail', $this->displayCharset); $this->mailPreferences = ExecMethod('felamimail.bopreferences.getPreferences'); $this->t->set_unknowns('remove'); $this->rowColor[0] = $GLOBALS['phpgw_info']["theme"]["bg01"]; $this->rowColor[1] = $GLOBALS['phpgw_info']["theme"]["bg02"]; if (!isset($GLOBALS['phpgw']->css) || !is_object($GLOBALS['phpgw']->css)) { $GLOBALS['phpgw']->css = createObject('phpgwapi.css'); } $GLOBALS['phpgw']->css->validate_file('app', 'felamimail'); }
function _moduleContent(&$smarty, $module_name) { //include elastix framework include_once "libs/paloSantoGrid.class.php"; include_once "libs/paloSantoValidar.class.php"; include_once "libs/paloSantoConfig.class.php"; include_once "libs/misc.lib.php"; include_once "libs/paloSantoForm.class.php"; include_once "libs/xajax/xajax.inc.php"; //include module files include_once "modules/{$module_name}/configs/default.conf.php"; include_once "modules/{$module_name}/libs/paloSantoDeleteModule.class.php"; global $arrConf; //include lang local module global $arrLangModule; $lang = get_language(); $lang_file = "modules/{$module_name}/lang/{$lang}.lang"; $base_dir = dirname($_SERVER['SCRIPT_FILENAME']); if (file_exists("{$base_dir}/{$lang_file}")) { include_once $lang_file; } else { include_once "modules/{$module_name}/lang/en.lang"; } //folder path for custom templates $base_dir = dirname($_SERVER['SCRIPT_FILENAME']); $templates_dir = isset($arrConfig['templates_dir']) ? $arrConfig['templates_dir'] : 'themes'; $local_templates_dir = "{$base_dir}/modules/{$module_name}/" . $templates_dir . '/' . $arrConf['theme']; require_once 'libs/paloSantoDB.class.php'; $pDB_acl = new paloDB($arrConf['elastix_dsn']['acl']); if (!empty($pDB_acl->errMsg)) { echo "ERROR DE DB: {$pDB_acl->errMsg} <br>"; } $pDB_menu = new paloDB($arrConf['elastix_dsn']['menu']); if (!empty($pDB_menu->errMsg)) { echo "ERROR DE DB: {$pDB_menu->errMsg} <br>"; } $xajax = new xajax(); $xajax->registerFunction("mostrar_menu"); $xajax->processRequests(); $content = $xajax->printJavascript("libs/xajax/"); $delete = isset($_POST['delete']) ? $_POST['delete'] : ''; if ($delete != '') { $accion = 'delete_module'; } else { $accion = "report_delete_module"; } switch ($accion) { case 'delete_module': $content .= delete_module($smarty, $module_name, $local_templates_dir, $arrLangModule, $pDB_acl, $pDB_menu); break; default: $content .= report_delete_module($smarty, $module_name, $local_templates_dir, $arrLangModule, $pDB_acl); break; } return $content; }
function _moduleContent(&$smarty, $module_name) { //include module files include_once "modules/{$module_name}/configs/default.conf.php"; include_once "modules/{$module_name}/libs/paloSantoIncomingcallsmonitoring.class.php"; // incluci� del xajax $xajax = new xajax(); $xajax->waitCursorOff(); $xajax->registerFunction("create_report"); $xajax->processRequests(); $content = $xajax->printJavascript("libs/xajax/"); //include file language agree to elastix configuration //if file language not exists, then include language by default (en) $lang = get_language(); $base_dir = dirname($_SERVER['SCRIPT_FILENAME']); $lang_file = "modules/{$module_name}/lang/{$lang}.lang"; if (file_exists("{$base_dir}/{$lang_file}")) { include_once "{$lang_file}"; } else { include_once "modules/{$module_name}/lang/en.lang"; } //global variables global $arrConf; global $arrConfModule; global $arrLang; global $arrLangModule; $arrConf = array_merge($arrConf, $arrConfModule); $arrLang = array_merge($arrLang, $arrLangModule); //folder path for custom templates $templates_dir = isset($arrConf['templates_dir']) ? $arrConf['templates_dir'] : 'themes'; $local_templates_dir = "{$base_dir}/modules/{$module_name}/" . $templates_dir . '/' . $arrConf['theme']; //conexion resource $pDB = new paloDB($arrConf['dsn_conn_database']); // $pDB = ""; //actions $accion = getAction(); switch ($accion) { default: $content .= '<div id="body_report">' . reportIncomingcallsmonitoring($smarty, $module_name, $local_templates_dir, $pDB, $arrConf, $arrLang) . '</div>'; break; } return $content; }
header('Content-Type: text/html; charset=utf-8'); header('Expires: Sat, 01 Jan 2000 00:00:00 GMT'); header('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); header('Cache-Control: post-check=0, pre-check=0', false); header('Pragma: no-cache'); session_cache_limiter('public, no-store'); session_set_cookie_params(0); if (!session_id()) { session_start(); } setcookie('PHPSESSID', session_id()); if ($_SESSION['curuser']['usertype'] != 'admin' && $_SESSION['curuser']['usertype'] != 'groupadmin') { header("Location: portal.php"); } require_once "include/xajax.inc.php"; require_once 'include/localization.class.php'; $GLOBALS['locate'] = new Localization($_SESSION['curuser']['country'], $_SESSION['curuser']['language'], 'remindercalls'); $xajax = new xajax("remindercalls.server.php"); $xajax->registerFunction("showGrid"); $xajax->registerFunction("add"); $xajax->registerFunction("save"); $xajax->registerFunction("edit"); $xajax->registerFunction("update"); $xajax->registerFunction("delete"); $xajax->registerFunction("init"); $xajax->registerFunction("searchFormSubmit"); $xajax->registerFunction("setAsteriskcalls"); define("ROWSXPAGE", 10); // Number of rows show it per page. define("MAXROWSXPAGE", 25); // Total number of rows show it when click on "Show All" button.
<?php /* For licensing terms, see /license.txt */ /** * @package chamilo.admin * @todo use formvalidator */ // name of the language file that needs to be included $language_file = 'admin'; // resetting the course id $cidReset = true; require_once '../inc/global.inc.php'; $id_session = isset($_GET['id_session']) ? intval($_GET['id_session']) : null; SessionManager::protect_session_edit($id_session); $xajax = new xajax(); $xajax->registerFunction(array('search_courses', 'AddCourseToSession', 'search_courses')); // Setting the section (for the tabs) $this_section = SECTION_PLATFORM_ADMIN; // setting breadcrumbs $interbreadcrumb[] = array('url' => 'index.php', 'name' => get_lang('Sessions')); $interbreadcrumb[] = array('url' => 'session_list.php', 'name' => get_lang('SessionList')); $interbreadcrumb[] = array('url' => "resume_session.php?id_session=" . $id_session, "name" => get_lang('SessionOverview')); // Database Table Definitions $tbl_session_rel_course_rel_user = Database::get_main_table(TABLE_MAIN_SESSION_COURSE_USER); $tbl_session = Database::get_main_table(TABLE_MAIN_SESSION); $tbl_session_rel_user = Database::get_main_table(TABLE_MAIN_SESSION_USER); $tbl_session_rel_course = Database::get_main_table(TABLE_MAIN_SESSION_COURSE); $tbl_course = Database::get_main_table(TABLE_MAIN_COURSE); // setting the name of the tool $tool_name = get_lang('SubscribeCoursesToSession'); $add_type = 'multiple';
********************************************************************************/ header('Content-Type: text/html; charset=utf-8'); header('Expires: Sat, 01 Jan 2000 00:00:00 GMT'); header('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); header('Cache-Control: post-check=0, pre-check=0', false); header('Pragma: no-cache'); session_cache_limiter('public, no-store'); session_set_cookie_params(0); if (!session_id()) { session_start(); } setcookie('PHPSESSID', session_id()); require_once 'include/localization.class.php'; if ($_SESSION['curuser']['usertype'] == 'clid' || $_SESSION['curuser']['usertype'] == '') { header("Location: index.php"); } elseif ($_SESSION['curuser']['usertype'] != 'admin' && $_SESSION['curuser']['usertype'] != 'reseller' && $_SESSION['curuser']['usertype'] != 'groupadmin') { header("Location: systemstatus.php"); } require_once "include/xajax.inc.php"; $GLOBALS['locate'] = new Localization($_SESSION['curuser']['country'], $_SESSION['curuser']['language'], 'import'); $xajax = new xajax("import.server.php"); $xajax->registerFunction("selectTable"); $xajax->registerFunction("init"); $xajax->registerFunction("submitForm"); $xajax->registerFunction("showDivMainRight"); $xajax->registerFunction("setGroup"); $xajax->registerFunction("deleteFile"); define("ROWSXPAGE", 5); // Number of rows show it per page. define("MAXROWSXPAGE", 25); // Total number of rows show it when click on "Show All" button.
<?php require_once $_SERVER['DOCUMENT_ROOT'] . '/Source/serviciotecnico/utilidades/xajax/xajax.inc.php'; require_once $_SERVER['DOCUMENT_ROOT'] . '/Source/eventos/estadoResultados.php'; $xajax = new xajax(); $xajax->registerFunction("mostrarer"); $xajax->processRequests(); ?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> <title>Sistema EDUGER</title> <script type="text/javascript" src="jscalendar/calendar.js"></script> <script type="text/javascript" src="jscalendar/lang/calendar-en.js"></script> <script type="text/javascript" src="jscalendar/calendar-setup.js"></script> <script src="SpryAssets/SpryMenuBar.js" type="text/javascript"></script> <style type="text/css"> @import url(ccs/styleMain.css); @import url(ccs/styleTabla.css); @import url(SpryAssets/SpryMenuBarHorizontal.css); @import url(jscalendar/calendar-blue.css); </style> <?php $xajax->printJavascript("../serviciotecnico/utilidades/xajax/"); ?> <style type="text/css"> <!-- .style8 { font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 10px;
<?php /* For licensing terms, see /license.txt */ /** * @package chamilo.admin */ // name of the language file that needs to be included $language_file = array('admin', 'registration'); // resetting the course id $cidReset = true; // including some necessary files ////require_once '../inc/global.inc.php'; require_once '../inc/lib/xajax/xajax.inc.php'; $xajax = new xajax(); $xajax->registerFunction('search_users'); // setting the section (for the tabs) $this_section = SECTION_PLATFORM_ADMIN; $id_session = intval($_GET['id_session']); $addProcess = isset($_GET['add']) ? Security::remove_XSS($_GET['add']) : null; SessionManager::protect_session_edit($id_session); // setting breadcrumbs $interbreadcrumb[] = array('url' => 'index.php', 'name' => get_lang('PlatformAdmin')); $interbreadcrumb[] = array('url' => 'session_list.php', 'name' => get_lang('SessionList')); $interbreadcrumb[] = array('url' => "resume_session.php?id_session=" . $id_session, "name" => get_lang('SessionOverview')); // Database Table Definitions $tbl_session = Database::get_main_table(TABLE_MAIN_SESSION); $tbl_course = Database::get_main_table(TABLE_MAIN_COURSE); $tbl_user = Database::get_main_table(TABLE_MAIN_USER); $tbl_session_rel_user = Database::get_main_table(TABLE_MAIN_SESSION_USER); // setting the name of the tool $tool_name = get_lang('SubscribeUsersToSession');
return $objResponse->getXML(); } function testClassMethod($formData) { $objResponse = new xajaxResponse(); $objResponse->addAlert("This is a class method."); $objResponse->addAlert("formData: " . print_r($formData, true)); $objResponse->addAssign("submittedDiv", "innerHTML", nl2br(print_r($formData, true))); return $objResponse->getXML(); } } $xajax = new xajax(); //$xajax->debugOn(); $myObj = new myObjectTest(); $myObj->myNumber = 50; $xajax->registerFunction(array("testForm", &$myObj, "testInstanceMethod")); $xajax->registerFunction(array("testForm2", "myObjectTest", "testClassMethod")); $myObj->myNumber = 56; $xajax->processRequests(); ?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/2000/REC-xhtml1-20000126/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <title>Register Object Test | xajax Tests</title> <?php $xajax->printJavascript("../"); ?> </head> <body>
require_once CACTI_BASE_PATH . "/lib/script/script_info.php"; require_once CACTI_BASE_PATH . "/lib/sys/sequence.php"; require_once CACTI_BASE_PATH . "/include/data_query/data_query_constants.php"; require_once CACTI_BASE_PATH . "/include/data_source/data_source_constants.php"; require_once CACTI_BASE_PATH . "/include/data_source/data_source_form.php"; require_once CACTI_BASE_PATH . "/lib/graph_tree/graph_tree_utility.php"; require_once CACTI_BASE_PATH . "/lib/sys/html_tree.php"; require_once CACTI_BASE_PATH . "/lib/utility.php"; require_once CACTI_BASE_PATH . "/lib/template.php"; /* set default action */ if (!isset($_REQUEST["action"])) { $_REQUEST["action"] = ""; } require_once CACTI_BASE_PATH . "/lib/xajax/xajax.inc.php"; $xajax = new xajax(); $xajax->registerFunction("_data_preset_rra_item_xajax_save"); $xajax->registerFunction("_data_preset_rra_item_xajax_remove"); $xajax->processRequests(); switch ($_REQUEST["action"]) { case 'save': form_save(); break; case 'item_add': require_once CACTI_BASE_PATH . "/include/top_header.php"; template_edit(); include_once "./include/bottom_footer.php"; break; case 'item_remove': template_item_remove(); break; case 'sv_remove':
require_once "../xajax_core/xajax.inc.php"; function returnStatus($number) { if ($number == 500) { header("HTTP/1.1 500 Internal Server Error"); echo "Testing a server error..."; } if ($number == 404) { header("HTTP/1.1 404 Not Found"); echo "Testing an unknown URL..."; } exit; } $xajax = new xajax(); $xajax->setFlag("debug", true); $xajax->registerFunction("returnStatus"); $xajax->processRequest(); ?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/2000/REC-xhtml1-20000126/DTD/xhtml1-transitional.dtd"> <html xmlns = "http://www.w3.org/1999/xhtml"> <head> <title>HTTP Status Test | xajax Tests</title> <?php $xajax->printJavascript("../"); ?> </head> <body>
/** * Uses new functions (php 5.2) for displaying real upload progress. * @param string $upload_id The value of the field UPLOAD_IDENTIFIER, the second parameter (XXX) of the $form->addElement('file', XXX) sentence * @param string $element_after The first element of the form (to place at first UPLOAD_IDENTIFIER) * @param int $delay (optional) The frequency of the xajax call * @param bool $wait_after_upload (optional) */ public function add_real_progress_bar($upload_id, $element_after, $delay = 2, $wait_after_upload = false) { if (!function_exists('uploadprogress_get_info')) { $this->add_progress_bar($delay); return; } $xajax_upload = new xajax(api_get_path(WEB_LIBRARY_PATH) . 'upload.xajax.php'); $xajax_upload->registerFunction('updateProgress'); // IMPORTANT : must be the first element of the form $el = $this->insertElementBefore(FormValidator::createElement('html', '<input type="hidden" name="UPLOAD_IDENTIFIER" value="' . $upload_id . '" />'), $element_after); $this->addElement('html', '<br />'); // Add div-element where the progress bar is to be displayed $this->addElement('html', ' <div id="dynamic_div_container" style="display:none"> <div id="dynamic_div_label">' . get_lang('UploadFile') . '</div> <div id="dynamic_div_frame" style="width:214px; height:12px; border:1px solid grey; background-image:url(' . api_get_path(WEB_IMG_PATH) . 'real_upload_frame.gif);"> <div id="dynamic_div_filled" style="width:0%;height:100%;background-image:url(' . api_get_path(WEB_IMG_PATH) . 'real_upload_step.gif);background-repeat:repeat-x;background-position:center;"></div> </div> </div>'); if ($wait_after_upload) { $this->addElement('html', ' <div id="dynamic_div_waiter_container" style="display:none"> <div id="dynamic_div_waiter_label"> ' . get_lang('SlideshowConversion') . ' </div> <div id="dynamic_div_waiter_frame"> <img src="' . api_get_path(WEB_IMG_PATH) . 'real_upload_frame.gif" /> </div> </div> '); } // Get the xajax code $this->addElement('html', $xajax_upload->getJavascript(api_get_path(WEB_LIBRARY_PATH) . 'xajax')); // Get the upload code $this->addElement('html', api_get_js('js/upload.js')); $this->addElement('html', '<script type="text/javascript">var myUpload = new upload(' . abs(intval($delay)) * 1000 . ');</script>'); if (!$wait_after_upload) { $wait_after_upload = 0; } // Add the upload event $this->updateAttributes("onsubmit=\"javascript: myUpload.startRealUpload('dynamic_div','" . $upload_id . "','" . $this->getAttribute('id') . "'," . $wait_after_upload . ")\""); }
* - html_assets_select() * - remove_asset() * - change_asset_severity() * - draw_asset_details() * - add_asset() * - edit_process() * Classes list: */ require_once 'classes/Session.inc'; require_once 'classes/Security.inc'; require_once 'classes/Xajax.inc'; require_once 'classes/Business_Process.inc'; Session::logcheck("MenuControlPanel", "BusinessProcesses"); Session::logcheck("MenuControlPanel", "BusinessProcessesEdit"); $xajax = new xajax(); $xajax->registerFunction("draw_assets"); $xajax->registerFunction("add_asset"); $xajax->registerFunction("remove_asset"); $xajax->registerFunction("draw_asset_details"); $xajax->registerFunction("change_asset_severity"); $xajax->registerFunction("edit_process"); $db = new ossim_db(); $conn = $db->connect(); $id = GET('id'); ossim_valid($id, OSS_DIGIT, 'illegal:ID'); if (ossim_error()) { die(ossim_error()); } function draw_assets($selected_value) { global $conn, $id;
<?php // multiply.php, multiply.common.php, multiply.server.php // demonstrate a very basic xajax implementation // using xajax version 0.2 // http://xajaxproject.org require_once $phpbb_root_path . 'includes/xajax/xajax.inc.php'; $xajax = new xajax($phpbb_root_path . 'includes/xajax/userinfo/update/update.server.php'); $xajax->registerFunction("update");
$response->assign("result", "style.display", "block"); return $response; } $sql = "delete from hangee_test where uid={$uid}"; $res = mysql_query($sql, $dbconn); if (!$res) { $msg = "query failed: {$sql} : " . mysql_error($dbconn); $response->assign("result", "innerHTML", $msg); $response->assign("result", "style.display", "block"); return $response; } $response->script("document.location.href='tester_hangee.php'"); return $response; } $xajax = new xajax(); $xajax->registerFunction("populate_pages"); $xajax->registerFunction("add_test_words"); $xajax->registerFunction("start_test"); $xajax->registerFunction("clear_list"); $xajax->registerFunction("register_new_test"); $xajax->processRequest(); ########################################################################### hangee_header("HanGEE: Tester"); $xajax->printJavascript("xajax"); ?> <script language='javascript' type='text/javascript'> <!--// function destroy_test_condition() {
// $objResponse->assign('div2', 'innerHTML', $query); $objResponse->assign('content', 'innerHTML', $updated); $objResponse->assign('input', 'innerHTML', $inputDiv); $objResponse->call('bottom'); //div scolling return $objResponse; } /* Section: Register functions - <savePay> - <deleteId> - <cosmetic> - <preview> */ $reqSavePayBtn =& $xajax->registerFunction('savePay'); $reqDelBtn =& $xajax->registerFunction('deleteId'); $reqCosmetic =& $xajax->registerFunction('cosmetic'); $reqInquiry =& $xajax->registerFunction('inquiry'); $reqInquiry->setParameter(0, XAJAX_INPUT_VALUE, 'sale_code'); $reqInquiry->setParameter(1, XAJAX_INPUT_VALUE, 'date_start'); $reqInquiry->setParameter(2, XAJAX_INPUT_VALUE, 'date_end'); $reqPreview =& $xajax->registerFunction('preview'); $reqParent =& $xajax->registerFunction('parent'); $reqEditBt =& $xajax->registerFunction('editBt'); /* Section: processRequest This will detect an incoming xajax request, process it and exit. If this is not a xajax request, then it is a request to load the initial contents of the page (HTML).
<?php /** * ajax :: inits xajax & registers the functions * * @package ajax * @copyright Copyright 2007 rainer@langheiter.comn // http://edv.langheiter.com * @copyright Copyright 2003-2007 Zen Cart Development Team * @copyright Portions Copyright 2003 osCommerce * @license http://www.zen-cart.com/license/2_0.txt GNU Public License V2.0 * @version $Id: ajax.common.php 72 2008-11-25 03:44:18Z yellow1912 $ */ // pi_1.php, pi_1.common.php, pi_1.server.php // demonstrate a very basic xajax implementation // using xajax version 0.5 // http://xajaxproject.org require_once DIR_FS_CATALOG . "ajax/xajax5/xajax_core/xajax.inc.php"; #require_once ("ajax/xajax.inc.php"); $xajax = new xajax(); //$xajax->configure('debug', true); $xajax->configure("javascript URI", '../ajax/xajax5'); if (isset($ajax_func)) { foreach ($ajax_func as $key => $value) { if (true == $value) { $xajax->registerFunction($key); } } } $xajax->processRequest();
$objResponse->alert("This is from the invalid request handler"); return test2ndFunction($aArgs[0], $objResponse); } function testForm($formData) { $objResponse = new xajaxResponse(); $objResponse->alert("This is from the regular function"); return test2ndFunction($formData, $objResponse); } $xajax = new xajax(); $xajax->configure('javascript URI', '../'); $xajax->setFlag("errorHandler", true); $xajax->registerEvent(XAJAX_PROCESSING_EVENT_INVALID, "onInvalidRequest"); if (isset($_GET['registerFunction'])) { if (1 == $_GET['registerFunction']) { $xajax->registerFunction("testForm"); } } $xajax->processRequest(); ?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/2000/REC-xhtml1-20000126/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <title>onMissingFunction Event (used to be catch-all) Function Test | xajax Tests</title> <?php $xajax->printJavascript(); ?> </head> <body>
* such as xajax_init() init init html page * Revision 0.01 2007/11/21 15:25:00 modified by solo * Desc: page created ********************************************************************************/ header('Content-Type: text/html; charset=utf-8'); header('Expires: Sat, 01 Jan 2000 00:00:00 GMT'); header('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); header('Cache-Control: post-check=0, pre-check=0', false); header('Pragma: no-cache'); session_cache_limiter('public, no-store'); session_set_cookie_params(0); if (!session_id()) { session_start(); } setcookie('PHPSESSID', session_id()); error_reporting($_SESSION['error_report']); require_once 'include/localization.class.php'; if ($_SESSION['curuser']['usertype'] != 'admin' && $_SESSION['curuser']['usertype'] != 'groupadmin' && !is_array($_SESSION['curuser']['privileges']['user_online'])) { header("Location: portal.php"); } $GLOBALS['locate'] = new Localization($_SESSION['curuser']['country'], $_SESSION['curuser']['language'], 'user_online'); require_once "include/xajax.inc.php"; $xajax = new xajax("user_online.server.php"); $xajax->registerFunction("init"); $xajax->registerFunction("listReport"); $xajax->registerFunction("speedDate"); $xajax->registerFunction("getAgent");
<?php require_once $_SERVER['DOCUMENT_ROOT'] . '/Source/serviciotecnico/utilidades/xajax/xajax.inc.php'; require_once $_SERVER['DOCUMENT_ROOT'] . '/Source/eventos/fichaInventario.php'; $xajax = new xajax(); $xajax->registerFunction("mostrarFichaInventario"); $xajax->processRequests(); ?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> <title>Sistema EDUGER</title> <?php $xajax->printJavascript("../serviciotecnico/utilidades/xajax/"); ?> <script src="SpryAssets/SpryMenuBar.js" type="text/javascript"></script> <script type="text/javascript" src="jscalendar/calendar.js"></script> <script type="text/javascript" src="jscalendar/lang/calendar-en.js"></script> <script type="text/javascript" src="jscalendar/calendar-setup.js"></script> <link href="SpryAssets/SpryMenuBarHorizontal.css" rel="stylesheet" type="text/css" /> <style type="text/css"> <!-- .style8 { font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 10px; color: #FFFFFF; } --> </style> <style type="text/css"> @import url(ccs/styleMain.css);
$objResponse = new xajaxResponse(); $xajaxFiller = new xajaxElementFiller(); $xajaxFiller->setDefaultOptionName($GLOBALS['lang_Common_Select']); if ($provlist) { $objResponse->addAssign('lrState', 'innerHTML', '<select name="txtState" id="txtState"><option value="0">--- ' . $GLOBALS['lang_Common_Select'] . ' ---</option></select>'); $objResponse = $xajaxFiller->cmbFillerById($objResponse, $provlist, 1, 'lrState', 'txtState'); } else { $objResponse->addAssign('lrState', 'innerHTML', '<input type="text" name="txtState" id="txtState" value="">'); } $objResponse->addScript('document.getElementById("txtState").Focus();'); $objResponse->addScript("document.frmLocation.txtDistrict.options.length = 1;"); $objResponse->addAssign('status', 'innerHTML', ''); return $objResponse->getXML(); } $objAjax = new xajax(); $objAjax->registerFunction('populateStates'); $objAjax->processRequests(); $sysConst = new sysConf(); $locRights = $_SESSION['localRights']; if (isset($this->getArr['capturemode']) && $this->getArr['capturemode'] == 'addmode') { ?> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html> <head> <title></title> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <?php $objAjax->printJavascript(); ?> <script type="text/javascript" src="../../scripts/archive.js"></script>
<?php /* For licensing terms, see /license.txt */ /** * @package chamilo.admin */ // Resetting the course id. $cidReset = true; // Including some necessary files. //require_once '../inc/global.inc.php'; $xajax = new xajax(); $xajax->registerFunction('search'); // Setting the section (for the tabs). $this_section = SECTION_PLATFORM_ADMIN; // Access restrictions. api_protect_admin_script(true); // Setting breadcrumbs. $interbreadcrumb[] = array('url' => 'index.php', 'name' => get_lang('PlatformAdmin')); $interbreadcrumb[] = array('url' => 'usergroups.php', 'name' => get_lang('Classes')); // Setting the name of the tool. $tool_name = get_lang('SubscribeClassToCourses'); $add_type = 'multiple'; if (isset($_REQUEST['add_type']) && $_REQUEST['add_type'] != '') { $add_type = Security::remove_XSS($_REQUEST['add_type']); } $add = isset($_GET['add']) ? Security::remove_XSS($_GET['add']) : null; $htmlHeadXtra[] = $xajax->getJavascript('../inc/lib/xajax/'); $htmlHeadXtra[] = '<script> function add_user_to_session (code, content) { document.getElementById("user_to_add").value = ""; document.getElementById("ajax_list_users_single").innerHTML = "";
Modify the style.color of div1 */ function setColor($sColor) { $objResponse = new xajaxResponse(); $objResponse->assign('div1', 'style.color', $sColor); return $objResponse; } /* Section: Register functions - <helloWorld> - <setColor> */ $reqHelloWorldMixed =& $xajax->registerFunction('helloWorld'); $reqHelloWorldMixed->setParameter(0, XAJAX_JS_VALUE, 0); $reqHelloWorldAllCaps =& $xajax->registerFunction('helloWorld'); $reqHelloWorldAllCaps->setParameter(0, XAJAX_JS_VALUE, 1); $reqSetColor =& $xajax->registerFunction('setColor'); $reqSetColor->setParameter(0, XAJAX_INPUT_VALUE, 'colorselect'); /* Section: processRequest This will detect an incoming xajax request, process it and exit. If this is not a xajax request, then it is a request to load the initial contents of the page (HTML). Everything prior to this statement will be executed upon each request (whether it is for the initial page load or a xajax request. Everything after this statement will be executed only when the page is first loaded.
<?php include_once 'config.php'; inc_lib('tools/xajax/xajax.inc.php'); $xajax = new xajax('/procajax.php'); // $xajax->setFlag('debug',true); $xajax->registerFunction('vote'); $xajax->registerFunction('voteResult'); $xajax->registerFunction('addToCart'); $xajax->registerFunction('showSubscribeForm'); $xajax->registerFunction('showSubscribeResult'); $xajax->registerFunction('showOrderDetail'); $xajax->registerFunction('deleteCartItem'); $xajax->registerFunction('sendStuffExist'); function deleteCartItem($sGUID) { $aStuff = $_SESSION['cart'][$sGUID]; $iQuantity = $_SESSION['number']; $iSum = preg_replace('/(\\s|,00)+/i', '', $_SESSION['summa']); $iStuffQuantity = $aStuff['counter']; $iStuffSum = $aStuff['price'] * $iStuffQuantity; unset($_SESSION['cart'][$sGUID]); $_SESSION['number'] = $iQuantity - $iStuffQuantity; $_SESSION['summa'] = number_format($iSum - $iStuffSum, 2, ',', ' '); $oResponse = new xajaxResponse(); // $oResponse->alert($iQuantity.'_'.$iStuffQuantity.'_'.$iSum.'_'.$iStuffSum); $oResponse->script("\$('#stuff_{$sGUID}').remove();"); $oResponse->script("\$('#delim_{$sGUID}').remove();"); if ($sCartText = getCartText()) { $oResponse->assign('cart_count', 'innerHTML', $sCartText); }
* @copyright SourceBans (C)2007 SteamFriends.com. All rights reserved. * @package SourceBans * @link http://www.sourcebans.net * * @version $Id: sb-callback.php 140 2008-08-31 15:30:35Z peace-maker * ============================================================================= */ require_once 'xajax.inc.php'; include_once 'system-functions.php'; include_once 'user-functions.php'; $xajax = new xajax(); //$xajax->debugOn(); $xajax->setRequestURI(XAJAX_REQUEST_URI); global $userbank; if (isset($_COOKIE['aid'], $_COOKIE['password']) && $userbank->CheckLogin($_COOKIE['password'], $_COOKIE['aid'])) { $xajax->registerFunction("AddMod"); $xajax->registerFunction("RemoveMod"); $xajax->registerFunction("AddGroup"); $xajax->registerFunction("RemoveGroup"); $xajax->registerFunction("RemoveAdmin"); $xajax->registerFunction("RemoveSubmission"); $xajax->registerFunction("RemoveServer"); $xajax->registerFunction("UpdateGroupPermissions"); $xajax->registerFunction("UpdateAdminPermissions"); $xajax->registerFunction("AddAdmin"); $xajax->registerFunction("SetupEditServer"); $xajax->registerFunction("AddServerGroupName"); $xajax->registerFunction("AddServer"); $xajax->registerFunction("AddBan"); $xajax->registerFunction("EditGroup"); $xajax->registerFunction("RemoveProtest");
<?php /* For licensing terms, see /license.txt */ /** * Interface for assigning sessions to Human Resources Manager * @package chamilo.admin */ // name of the language file that needs to be included $language_file = 'admin'; // resetting the course id $cidReset = true; global $_configuration; // create an ajax object $xajax = new xajax(); $xajax->registerFunction('search_sessions'); // setting the section (for the tabs) $this_section = SECTION_PLATFORM_ADMIN; // Access restrictions api_protect_admin_script(true); // setting breadcrumbs $interbreadcrumb[] = array('url' => 'index.php', 'name' => get_lang('PlatformAdmin')); $interbreadcrumb[] = array('url' => 'user_list.php', 'name' => get_lang('UserList')); // Database Table Definitions $tbl_session = Database::get_main_table(TABLE_MAIN_SESSION); $tbl_session_rel_user = Database::get_main_table(TABLE_MAIN_SESSION_USER); $tbl_session_rel_access_url = Database::get_main_table(TABLE_MAIN_ACCESS_URL_REL_SESSION); // initializing variables $id_session = intval($_GET['id_session']); $user_id = intval($_GET['user']); $user_info = api_get_user_info($user_id); $user_anonymous = api_get_anonymous_id();
<?php require_once $_SERVER['DOCUMENT_ROOT'] . '/Source/serviciotecnico/utilidades/xajax/xajax.inc.php'; require_once $_SERVER['DOCUMENT_ROOT'] . '/Source/eventos/consultasHome.php'; $xajax = new xajax(); $xajax->registerFunction("mostrarCompras"); $xajax->registerFunction("mostrarVentas"); $xajax->processRequests(); ?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> <title>Sistema EDUGER</title> <?php $xajax->printJavascript("../serviciotecnico/utilidades/xajax/"); ?> <script src="SpryAssets/SpryMenuBar.js" type="text/javascript"></script> <link href="SpryAssets/SpryMenuBarHorizontal.css" rel="stylesheet" type="text/css" /> <style type="text/css"> <!-- .style8 { font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 10px; color: #FFFFFF; } --> </style> </head> <body> <table width="100%" border="0" cellspacing="0" cellpadding="0"> <tr>
header('Cache-Control: post-check=0, pre-check=0', false); header('Pragma: no-cache'); session_cache_limiter('public, no-store'); session_set_cookie_params(0); if (!session_id()) { session_start(); } setcookie('PHPSESSID', session_id()); if ($_SESSION['curuser']['usertype'] != 'admin' && $_SESSION['curuser']['usertype'] != 'groupadmin' && !is_array($_SESSION['curuser']['privileges']['note_leads'])) { header("Location: portal.php"); } require_once "include/xajax.inc.php"; require_once 'include/localization.class.php'; $GLOBALS['locate'] = new Localization($_SESSION['curuser']['country'], $_SESSION['curuser']['language'], 'astercrm'); $xajax = new xajax("note_leads.server.php"); $xajax->registerFunction("init"); $xajax->registerFunction("showGrid"); $xajax->registerFunction("export"); $xajax->registerFunction("delete"); $xajax->registerFunction("edit"); $xajax->registerFunction("save"); $xajax->registerFunction("showCustomer"); $xajax->registerFunction("showContact"); $xajax->registerFunction("update"); $xajax->registerFunction("add"); $xajax->registerFunction("searchFormSubmit"); $xajax->registerFunction("deleteByButton"); define("ROWSXPAGE", 10); // Number of rows show it per page. define("MAXROWSXPAGE", 25); // Total number of rows show it when click on "Show All" button.
********************************************************************************/ header('Content-Type: text/html; charset=utf-8'); header('Expires: Sat, 01 Jan 2000 00:00:00 GMT'); header('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); header('Cache-Control: post-check=0, pre-check=0', false); header('Pragma: no-cache'); session_cache_limiter('public, no-store'); session_set_cookie_params(0); if (!session_id()) { session_start(); } setcookie('PHPSESSID', session_id()); if ($_SESSION['curuser']['usertype'] != 'admin') { header("Location: portal.php"); } require_once "include/xajax.inc.php"; require_once 'include/localization.class.php'; $GLOBALS['locate'] = new Localization($_SESSION['curuser']['country'], $_SESSION['curuser']['language'], 'group'); $xajax = new xajax("group.server.php"); $xajax->registerFunction("showGrid"); $xajax->registerFunction("add"); $xajax->registerFunction("save"); $xajax->registerFunction("edit"); $xajax->registerFunction("update"); $xajax->registerFunction("init"); $xajax->registerFunction("showDetail"); $xajax->registerFunction("searchFormSubmit"); define("ROWSXPAGE", 10); // Number of rows show it per page. define("MAXROWSXPAGE", 25); // Total number of rows show it when click on "Show All" button.
* Revision 0.01 2007/11/21 15:25:00 modified by solo * Desc: page created ********************************************************************************/ header('Content-Type: text/html; charset=utf-8'); header('Expires: Sat, 01 Jan 2000 00:00:00 GMT'); header('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); header('Cache-Control: post-check=0, pre-check=0', false); header('Pragma: no-cache'); session_cache_limiter('public, no-store'); session_set_cookie_params(0); if (!session_id()) { session_start(); } setcookie('PHPSESSID', session_id()); error_reporting($_SESSION['error_report']); require_once 'include/localization.class.php'; if ($_SESSION['curuser']['usertype'] != 'admin' && $_SESSION['curuser']['usertype'] != 'groupadmin' && !is_array($_SESSION['curuser']['privileges']['report'])) { header("Location: portal.php"); } $GLOBALS['locate'] = new Localization($_SESSION['curuser']['country'], $_SESSION['curuser']['language'], 'report'); require_once "include/xajax.inc.php"; $xajax = new xajax("report.server.php"); $xajax->waitCursorOff(); $xajax->registerFunction("init"); $xajax->registerFunction("listReport"); $xajax->registerFunction("checkOut"); $xajax->registerFunction("setAccount"); $xajax->registerFunction("setClid"); $xajax->registerFunction("speedDate");