* Make request. * Allow the module's client code to make a request of its server code (class). * * Example ajax call: * * Ext.Ajax.request({ * url: this.app.connection, * // Could also pass the module id and action in querystring like this, * // instead of in the Ext.Ajax.request params config option. * * // url: this.app.connection+'?method=myMethodName&moduleId='+this.id, * params: { * method: 'myMethodName', * moduleId: this.id, * ... * }, * success: this.mySuccessFn, * failure: this.myFailureFn, * scope: this * }); */ $method_name = isset($_GET['method']) ? $_GET['method'] : $_POST['method']; $module_id = isset($_GET['moduleId']) ? $_GET['moduleId'] : $_POST['moduleId']; if (isset($module_id, $method_name) && $module_id != '' && $method_name != '') { require 'server/os.php'; if (class_exists('os')) { $os = new os(); $os->make_request($module_id, $method_name); } } }