public static function build() { // Check settings require_once NELIOAB_ADMIN_DIR . '/error-controller.php'; $error = NelioABErrorController::build_error_page_on_invalid_settings(); if ($error) { return; } $title = __('Results of the Experiment', 'nelioab'); $view = new NelioABEmptyAjaxPage($title); $controller = NelioABSelectExpProgressPageController::attempt_to_load_proper_controller(); if ($controller != NULL) { call_user_func(array($controller, 'build')); } else { if (isset($_GET['id'])) { // The ID of the experiment to which the action applies $view->keep_request_param('id', $_GET['id']); } if (isset($_GET['exp_type'])) { $view->keep_request_param('exp_type', $_GET['exp_type']); } if (isset($_GET['goal'])) { $view->keep_request_param('goal', $_GET['goal']); } $view->get_content_with_ajax_and_render(__FILE__, __CLASS__); } }
public static function build() { $title = __('Edit Experiment', 'nelioab'); $view = new NelioABEmptyAjaxPage($title); $controller = NelioABSelectExpEditionPageController::attempt_to_load_proper_controller(); if ($controller != NULL) { call_user_func(array($controller, 'build')); } else { if (isset($_GET['id'])) { // The ID of the experiment to which the action applies $view->keep_request_param('id', $_GET['id']); } if (isset($_GET['exp_type'])) { $view->keep_request_param('exp_type', $_GET['exp_type']); } $view->get_content_with_ajax_and_render(__FILE__, __CLASS__); } }