/**
  * constructor to call the base constructor
  */
 public function __construct()
 {
     parent::__construct();
     //Increase max execution time
     if (@ini_get("max_execution_time") < 3600 && @ini_get("max_execution_time") > 0) {
         @ini_set("max_execution_time", "3600");
     }
 }
 /**
  * contructor to call the base constructor
  */
 public function __construct()
 {
     parent::__construct();
     $this->setStrTextBase("stats");
 }
 /**
  * constructor to call the base constructor
  */
 public function __construct()
 {
     parent::__construct();
     $this->setStrTextBase("pages");
     $this->setBitMultipartform(true);
 }
    /**
     * Renders the code to run and execute a systemtask. You only need this if you want to provide the user an additional place
     * to run a systemtask besides the common place at module system / admin.
     *
     * @param bool $bitExecute
     * @param class_systemtask_base $objTask
     * @param string $strModule
     * @param string $strAction
     * @param bool $bitExecuteDirectly
     *
     * @return string
     */
    public static function getTaskDialogExecuteCode($bitExecute, class_systemtask_base $objTask, $strModule = "", $strAction = "", $bitExecuteDirectly = false)
    {
        $objLang = class_carrier::getInstance()->getObjLang();
        $strTaskOutput = "";
        //If the task is going to be executed, validate the form first (if form is of type class_admin_formgenerator)
        $objAdminForm = null;
        if ($bitExecute) {
            $objAdminForm = $objTask->getAdminForm();
            if ($objAdminForm !== null && $objAdminForm instanceof class_admin_formgenerator) {
                if (!$objAdminForm->validateForm()) {
                    $bitExecute = false;
                }
            }
        }
        //execute the task or show the form?
        if ($bitExecute) {
            if ($bitExecuteDirectly) {
                $strTaskOutput .= $objTask->executeTask();
            } else {
                $strTaskOutput .= "\n                <script type=\"text/javascript\">\n                \$(function() {\n                   setTimeout(function() {\n                        KAJONA.admin.systemtask.executeTask('" . $objTask->getStrInternalTaskname() . "', '" . $objTask->getSubmitParams() . "');\n                        KAJONA.admin.systemtask.setName('" . $objLang->getLang("systemtask_runningtask", "system") . " " . $objTask->getStrTaskName() . "');\n                   }, 500);\n                 });\n                </script>";
            }
        } else {
            $strForm = $objTask->generateAdminForm($strModule, $strAction, $objAdminForm);
            if ($strForm != "") {
                $strTaskOutput .= $strForm;
            } else {
                $strLang = class_carrier::getInstance()->getObjLang()->getLang("systemtask_runningtask", "system");
                $strTaskJS = <<<JS
                \$(function() {
                    setTimeout(function() {
                        KAJONA.admin.systemtask.executeTask('{$objTask->getStrInternalTaskName()}', '');
                        KAJONA.admin.systemtask.setName('{$strLang} {$objTask->getStrTaskName()}');
                    }, 500);
                });
JS;
                $strTaskOutput .= "<script type='text/javascript'>" . $strTaskJS . "</script>";
            }
        }
        return $strTaskOutput;
    }
 /**
  * contructor to call the base constructor
  */
 public function __construct()
 {
     parent::__construct();
     //set the correct text-base
     $this->setStrTextBase("navigation");
 }
 /**
  * contructor to call the base constructor
  */
 public function __construct()
 {
     parent::__construct();
     $this->setStrTextBase("workflows");
 }