$row = Form::label("pw2", _("Re-enter Password") . ":", array('class' => 'required')); $row .= Form::password("pwd2", isset($formVar["pwd2"]) ? $formVar["pwd2"] : null, array('size' => 20, 'error' => isset($formError["pwd2"]) ? $formError["pwd2"] : null)); $row .= Form::hidden("md5_confirm"); $tbody[] = $row; } $row = Form::label("email", _("Email") . ":"); $row .= Form::text("email", isset($formVar["email"]) ? $formVar["email"] : null, array('size' => 40, 'error' => isset($formError["email"]) ? $formError["email"] : null)); $tbody[] = $row; if (!isset($_GET["all"])) { $row = Form::label("actived", _("Actived") . ":"); $row .= Form::checkBox("actived", 1, array('checked' => isset($formVar["actived"]) ? $formVar["actived"] != "" : false)); $tbody[] = $row; if (!isset($formVar["id_profile"]) || $formVar["id_profile"] == "") { $formVar["id_profile"] = OPEN_PROFILE_DOCTOR; // by default doctor profile } $array = array(OPEN_PROFILE_ADMINISTRATOR => _("Administrator"), OPEN_PROFILE_ADMINISTRATIVE => _("Administrative"), OPEN_PROFILE_DOCTOR => _("Doctor")); $row = Form::label("id_profile", _("Profile") . ":", array('class' => 'required')); $row .= Form::select("id_profile", $array, $formVar["id_profile"]); unset($array); $tbody[] = $row; } $row = Form::label("id_theme", _("Theme") . ":"); $row .= Form::selectTable("theme_tbl", "id_theme", isset($formVar["id_theme"]) ? $formVar["id_theme"] : null, "theme_name"); $tbody[] = $row; $tfoot = array(Form::button("save", _("Submit")) . Form::generateToken()); echo Form::fieldset($title, $tbody, $tfoot); if (isset($_GET["all"])) { echo Form::hidden("actived", "checked"); echo Form::hidden("id_profile", $formVar["id_profile"]); }
unset($links); echo HTML::para(HTML::link(_("Add New Theme"), '../admin/theme_new_form.php')); /** * Search in database */ $themeQ = new Query_Theme(); if (!$themeQ->selectWithStats()) { $themeQ->close(); echo Msg::info(_("No results found.")); include_once "../layout/footer.php"; exit; } if ($themeQ->numRows() > 1) { $legend = _("Change Theme by default in application"); $content = Form::label("id_theme", _("Choose a New Theme:")); $content .= Form::selectTable("theme_tbl", "id_theme", OPEN_THEME_ID, "theme_name"); $body = array($content); $foot = array(Form::button("button1", _("Update"))); /** * Theme use form */ echo HTML::start('form', array('method' => 'post', 'action' => '../admin/theme_use.php')); echo Form::fieldset($legend, $body, $foot); echo HTML::end('form'); } echo HTML::section(2, _("Themes List:")); $thead = array(_("#"), _("Function") => array('colspan' => 5), _("Theme Name"), _("Usage")); $validateLink = "http://" . $_SERVER['HTTP_HOST'] . $_SERVER['PHP_SELF']; $validateLink = str_replace("/admin/", "/css/", $validateLink); $validateLink = substr($validateLink, 0, strrpos($validateLink, "/") + 1); $validateLink = "http://jigsaw.w3.org/css-validator/validator?uri=" . $validateLink;
$body[] = $row; $row = Form::label("items_per_page", _("Search Results") . ":", array('class' => 'required')); $row .= Form::text("items_per_page", $formVar["items_per_page"], array('size' => 3, 'error' => isset($formError["items_per_page"]) ? $formError["items_per_page"] : null)); $row .= _("items per page") . "**"; $body[] = $row; if (defined("OPEN_DEMO") && !OPEN_DEMO) { $row = Form::label("language", _("Language") . ":"); $languageList = I18n::languageList(); $row .= Form::select("language", $languageList, $formVar["language"]); $body[] = $row; } elseif (defined("OPEN_DEMO") && OPEN_DEMO) { $row = Form::hidden("language", "en"); $body[] = $row; } $row = Form::label("id_theme", _("Theme by default") . ":"); $row .= Form::selectTable("theme_tbl", "id_theme", $formVar["id_theme"], "theme_name"); $body[] = $row; $appFields = Form::fieldset(_("Application"), $body); $body = array(); $row = Form::label("clinic_name", _("Clinic Name") . ":"); $row .= Form::text("clinic_name", isset($formVar["clinic_name"]) ? $formVar["clinic_name"] : null, array('size' => 40, 'maxlength' => 128, 'error' => isset($formError["clinic_name"]) ? $formError["clinic_name"] : null)); $body[] = $row; $row = Form::label("clinic_hours", _("Clinic Hours") . ":"); $row .= Form::text("clinic_hours", isset($formVar["clinic_hours"]) ? $formVar["clinic_hours"] : null, array('size' => 40, 'maxlength' => 128, 'error' => isset($formError["clinic_hours"]) ? $formError["clinic_hours"] : null)); $body[] = $row; $row = Form::label("clinic_address", _("Clinic Address") . ":"); $row .= Form::textArea("clinic_address", isset($formVar["clinic_address"]) ? $formVar["clinic_address"] : null, array('rows' => 3, 'cols' => 30)); $body[] = $row; $row = Form::label("clinic_phone", _("Clinic Phone") . ":"); $row .= Form::text("clinic_phone", isset($formVar["clinic_phone"]) ? $formVar["clinic_phone"] : null, array('size' => 40, 'error' => isset($formError["clinic_phone"]) ? $formError["clinic_phone"] : null)); $body[] = $row;