本文整理汇总了PHP中ilTextInputGUI类的典型用法代码示例。如果您正苦于以下问题:PHP ilTextInputGUI类的具体用法?PHP ilTextInputGUI怎么用?PHP ilTextInputGUI使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
在下文中一共展示了ilTextInputGUI类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。
示例1: editQuestion
/**
* Creates an output of the edit form for the question
* @access public
*/
function editQuestion()
{
global $ilDB, $tpl;
$plugin = $this->object->getPlugin();
$this->getQuestionTemplate();
include_once "./Services/Form/classes/class.ilPropertyFormGUI.php";
$form = new ilPropertyFormGUI();
$form->setFormAction($this->ctrl->getFormAction($this));
$form->setTitle($this->outQuestionType());
$form->setMultipart(FALSE);
$form->setTableWidth("100%");
$form->setId("assJSMEQuestion");
// Basiseingabefelder: title, author, description, question, working time (assessment mode)
$this->addBasicQuestionFormProperties($form);
// points
$points = new ilNumberInputGUI($plugin->txt("points"), "points");
$points->setValue($this->object->getPoints());
$points->setRequired(TRUE);
$points->setSize(10);
$points->setMinValue(0.0);
$form->addItem($points);
// optionString for the JSME-Applet
include_once "./Services/Form/classes/class.ilTextInputGUI.php";
$optionString = new ilTextInputGUI($plugin->txt("optionString"), "optionString");
$optionString->setValue($this->object->getOptionString());
$form->addItem($optionString);
// JSME-Applet for sampleSolution
include_once "./Services/Form/classes/class.ilCustomInputGUI.php";
$sampleSolution = new ilCustomInputGUI($plugin->txt("sampleSolution"), "sampleSolution");
$template = $this->getJsmeOutputTemplate("", $this->object->getOptionString(), $this->object->getSampleSolution());
$sampleSolution->setHtml($template->get());
$form->addItem($sampleSolution);
$form->addCommandButton('save', $plugin->txt("save"));
$this->tpl->setVariable("QUESTION_DATA", $form->getHTML());
}
开发者ID:ba-al,项目名称:ILIAS-ChemistryQuestion44,代码行数:39,代码来源:class.assJSMEQuestionGUI.php
示例2: initForm
/**
* Init form.
*
* @param string $a_mode edit mode
*/
public function initForm($a_mode = "edit")
{
global $lng, $ilCtrl;
include_once "Services/Form/classes/class.ilPropertyFormGUI.php";
$this->form = new ilPropertyFormGUI();
// title
$ti = new ilTextInputGUI($lng->txt("title"), "title");
$ti->setMaxLength(200);
$ti->setSize(50);
$ti->setRequired(true);
$this->form->addItem($ti);
// order nr
$ni = new ilNumberInputGUI($lng->txt("skmg_order_nr"), "order_nr");
$ni->setMaxLength(6);
$ni->setSize(6);
$ni->setRequired(true);
$this->form->addItem($ni);
// save and cancel commands
if ($a_mode == "create") {
$this->form->addCommandButton("save", $lng->txt("save"));
$this->form->addCommandButton("cancelSave", $lng->txt("cancel"));
$this->form->setTitle($lng->txt("skmg_create_skll"));
} else {
$this->form->addCommandButton("update", $lng->txt("save"));
$this->form->setTitle($lng->txt("skmg_edit_skll"));
}
$ilCtrl->setParameter($this, "obj_id", $_GET["obj_id"]);
$this->form->setFormAction($ilCtrl->getFormAction($this));
}
开发者ID:arlendotcn,项目名称:ilias,代码行数:34,代码来源:class.ilBasicSkillTemplateGUI.php
示例3: initForm
/**
* Init settings property form
*
* @access private
*/
private function initForm()
{
$this->setFormAction($this->ctrl->getFormAction($this->parent_gui));
$name = new ilTextInputGUI($this->lng->txt("bibl_library_name"), 'name');
$name->setRequired(true);
$name->setValue('');
$this->addItem($name);
$url = new ilTextInputGUI($this->lng->txt("bibl_library_url"), 'url');
$url->setRequired(true);
$url->setValue('');
$this->addItem($url);
$img = new ilTextInputGUI($this->lng->txt("bibl_library_img"), 'img');
$img->setValue('');
$this->addItem($img);
$show_in_list = new ilCheckboxInputGUI($this->lng->txt("bibl_library_show_in_list"), 'show_in_list');
$show_in_list->setValue(1);
$this->addItem($show_in_list);
switch ($this->action) {
case 'create':
$this->setTitle($this->lng->txt("bibl_settings_new"));
$this->addCommandButton('create', $this->lng->txt('save'));
break;
case 'update':
$this->addCommandButton('update', $this->lng->txt('save'));
$this->fillForm();
$this->setTitle($this->lng->txt("bibl_settings_edit"));
break;
}
$this->addCommandButton('cancel', $this->lng->txt("cancel"));
}
开发者ID:arlendotcn,项目名称:ilias,代码行数:35,代码来源:class.ilObjBibliographicAdminLibrariesFormGUI.php
示例4: addToForm
public function addToForm()
{
$def = $this->getADT()->getCopyOfDefinition();
if (!$this->isMulti()) {
$text = new ilTextInputGUI($this->getTitle(), $this->getElementId());
if ($def->getMaxLength()) {
$max = $def->getMaxLength();
$size = $text->getSize();
$text->setMaxLength($max);
if ($size && $max < $size) {
$text->setSize($max);
}
}
} else {
$text = new ilTextAreaInputGUI($this->getTitle(), $this->getElementId());
if ($this->multi_rows) {
$text->setRows($this->multi_rows);
}
if ($this->multi_cols) {
$text->setCols($this->multi_cols);
}
}
$this->addBasicFieldProperties($text, $def);
$text->setValue($this->getADT()->getText());
$this->addToParentElement($text);
}
开发者ID:arlendotcn,项目名称:ilias,代码行数:26,代码来源:class.ilADTTextFormBridge.php
示例5: showTrustees
public function showTrustees($a_show_delete = false)
{
global $ilToolbar;
$_SESSION['paya_delete_trustee'] = $_SESSION['paya_delete_trustee'] ? $_SESSION['paya_delete_trustee'] : array();
$actions = array(0 => $this->lng->txt("paya_disabled"), 1 => $this->lng->txt("paya_enabled"));
include_once "./Services/Form/classes/class.ilTextInputGUI.php";
$ul = new ilTextInputGUI($this->lng->txt("user"), "search_str");
$ul->setDataSource($this->ctrl->getLinkTarget($this, "performSearch", "", true));
$ul->setSize(20);
$ilToolbar->addInputItem($ul, true);
$ilToolbar->addFormButton($this->lng->txt("add"), "performSearch");
$ilToolbar->setFormAction($this->ctrl->getFormAction($this));
$this->tpl->addBlockfile('ADM_CONTENT', 'adm_content', 'tpl.main_view.html', 'Services/Payment');
if ($a_show_delete) {
$oConfirmationGUI = new ilConfirmationGUI();
// set confirm/cancel commands
$oConfirmationGUI->setFormAction($this->ctrl->getFormAction($this, "performDeleteTrustee"));
$oConfirmationGUI->setHeaderText($this->lng->txt("paya_sure_delete_selected_trustees"));
$oConfirmationGUI->setCancel($this->lng->txt("cancel"), "cancelDelete");
$oConfirmationGUI->setConfirm($this->lng->txt("confirm"), "performDeleteTrustee");
foreach ($this->trustee_obj->getTrustees() as $trustee) {
$delete_row = '';
if (in_array($trustee['trustee_id'], $_POST['trustee'])) {
if ($tmp_obj = ilObjectFactory::getInstanceByObjId($trustee['trustee_id'], false)) {
$delete_row = $tmp_obj->getLogin() . ' -> ' . $tmp_obj->getFirstname() . ' ' . $tmp_obj->getLastname();
}
}
$oConfirmationGUI->addItem('', $delete_row, $delete_row);
}
$this->tpl->setVariable("CONFIRMATION", $oConfirmationGUI->getHTML());
}
if (!count($this->trustee_obj->getTrustees())) {
ilUtil::sendInfo($this->lng->txt('paya_no_trustees'));
return true;
}
$counter = 0;
$f_result = array();
require_once 'Services/Mail/classes/class.ilMailFormCall.php';
foreach ($this->trustee_obj->getTrustees() as $trustee) {
// GET USER OBJ
if ($tmp_obj = ilObjectFactory::getInstanceByObjId($trustee['trustee_id'], false)) {
$f_result[$counter]['trustee_id'] = ilUtil::formCheckbox(in_array($trustee['trustee_id'], $_SESSION['paya_delete_trustee']) ? 1 : 0, "trustee[]", $trustee['trustee_id']);
$f_result[$counter]['login'] = $tmp_obj->getLogin();
$f_result[$counter]['firstname'] = $tmp_obj->getFirstname();
$f_result[$counter]['lastname'] = $tmp_obj->getLastname();
$f_result[$counter]['perm_stat'] = ilUtil::formSelect((int) $trustee['perm_stat'], 'perm_stat[' . $trustee['trustee_id'] . ']', $actions, false, true);
$f_result[$counter]['perm_obj'] = ilUtil::formSelect((int) $trustee['perm_obj'], 'perm_obj[' . $trustee['trustee_id'] . ']', $actions, false, true);
$f_result[$counter]['perm_coupons'] = ilUtil::formSelect((int) $trustee['perm_coupons'], 'perm_coupons[' . $trustee['trustee_id'] . ']', $actions, false, true);
# $link_mail = "<a target=\"_blank\" href=\"./ilias.php?baseClass=ilMailGUI&type=new&rcp_to=".
# $tmp_obj->getLogin()."\"".$img_mail."</a>";
$url_mail = ilMailFormCall::getLinkTarget($this, '', array(), array('type' => 'new', 'rcp_to' => $tmp_obj->getLogin()));
$link_mail = "<div class=\"il_ContainerItemCommands\"><a class=\"il_ContainerItemCommand\" href=\"" . $url_mail . "\">" . $this->lng->txt("mail") . "</a></div>";
$f_result[$counter]['options'] = $link_mail;
unset($tmp_obj);
++$counter;
}
}
return $this->__showTrusteesTable($f_result);
}
开发者ID:arlendotcn,项目名称:ilias,代码行数:59,代码来源:class.ilPaymentTrusteeGUI.php
示例6: addToForm
public function addToForm()
{
$text = new ilTextInputGUI($this->getTitle(), $this->getElementId());
$text->setMulti(true);
$this->addBasicFieldProperties($text, $this->getADT()->getCopyOfDefinition());
$text->setValue($this->getADT()->getTextElements());
$this->addToParentElement($text);
}
开发者ID:arlendotcn,项目名称:ilias,代码行数:8,代码来源:class.ilADTMultiTextFormBridge.php
示例7: initForm
protected function initForm()
{
$this->setTitle($this->lng->txt('admin_form_title'));
$te = new ilTextInputGUI($this->lng->txt('admin_origins_path'), 'path');
$te->setInfo($this->lng->txt('admin_origins_path_info'));
$this->addItem($te);
$this->addCommandButtons();
}
开发者ID:arlendotcn,项目名称:ilias,代码行数:8,代码来源:class.arConfigFormGUI.php
示例8: initFilter
/**
* Initialize the table filters.
*
* This method is called internally to initialize
* the filters from present on the top of the table.
*/
public function initFilter()
{
include_once 'Services/Form/classes/class.ilTextInputGUI.php';
$tname = new ilTextInputGUI($this->lng->txt('rep_robj_xtov_test_list_flt_tst_name'), 'flt_tst_name');
$tname->setSubmitFormOnEnter(true);
$this->addFilterItem($tname);
$tname->readFromSession();
$this->filter['flt_tst_name'] = $tname->getValue();
}
开发者ID:ionesoft,项目名称:TestOverview,代码行数:15,代码来源:class.ilTestListTableGUI.php
示例9: initConfigurationForm
/**
* Init configuration form.
*
* @return object form object
*/
public function initConfigurationForm()
{
global $lng, $ilCtrl, $ilDB;
$pl = $this->getPluginObject();
$this->getPluginObject()->includeClass('class.ilOpenmeetingsConfig.php');
$this->object = ilOpenmeetingsConfig::getInstance();
include_once "Services/Form/classes/class.ilPropertyFormGUI.php";
$this->form = new ilPropertyFormGUI();
$this->form->setTitle($pl->txt("openmeetings_plugin_configuration"));
$this->form->setFormAction($ilCtrl->getFormAction($this));
$this->form->addCommandButton("save", $lng->txt("save"));
// url (text)
$ti = new ilTextInputGUI($pl->txt("url"), "frmurl");
$ti->setRequired(true);
$ti->setMaxLength(256);
$ti->setSize(60);
$this->form->addItem($ti);
// port (text)
$ti = new ilTextInputGUI($pl->txt("port"), "frmport");
$ti->setRequired(true);
$ti->setMaxLength(10);
$ti->setSize(10);
$this->form->addItem($ti);
// appname
$ti = new ilTextInputGUI($pl->txt("appname"), "frmappname");
$ti->setRequired(true);
$ti->setMaxLength(32);
$ti->setSize(20);
$this->form->addItem($ti);
// username (text)
$ti = new ilTextInputGUI($pl->txt("username"), "frmusername");
$ti->setRequired(true);
$ti->setMaxLength(256);
$ti->setSize(20);
$this->form->addItem($ti);
// password (text)
$ti = new ilPasswordInputGUI($pl->txt("password"), "frmpassword");
$ti->setRequired(true);
$ti->setMaxLength(256);
$ti->setSize(20);
$ti->setRetype(false);
$this->form->addItem($ti);
foreach ($this->fields as $key => $item) {
$field = new $item["type"]($this->plugin_object->txt('conf_' . $key), $key);
$field->setInfo($this->plugin_object->txt($item["info"]));
if (is_array($item["subelements"])) {
foreach ($item["subelements"] as $subkey => $subitem) {
$subfield = new $subitem["type"]($this->plugin_object->txt('conf_' . $key . "_" . $subkey), $subkey);
$subfield->setInfo($this->plugin_object->txt($subitem["info"]));
$field->addSubItem($subfield);
}
}
$this->form->addItem($field);
}
return $this->form;
}
开发者ID:Uwe-Kohnle,项目名称:ilias_openmeetings_plugin,代码行数:61,代码来源:class.ilOpenmeetingsConfigGUI.php
示例10: showSettings
public function showSettings($item)
{
global $lng;
$txt = new ilTextInputGUI($lng->txt('polling_intervall'), 'osd_polling_intervall');
$txt->setRequired(true);
$txt->setInfo($lng->txt('polling_in_seconds'));
$txt->setValue('300');
$item->addSubItem($txt);
return array('osd_polling_intervall');
}
开发者ID:arlendotcn,项目名称:ilias,代码行数:10,代码来源:class.ilNotificationOSDHandler.php
示例11: initFilter
/**
* Init filter
*/
function initFilter()
{
global $lng, $rbacreview, $ilUser;
// title
include_once "./Services/Form/classes/class.ilTextInputGUI.php";
$ti = new ilTextInputGUI($lng->txt("title"), "title");
$ti->setMaxLength(64);
$ti->setSize(20);
$ti->setValidationRegexp('/^[^%]+$/is');
$this->addFilterItem($ti);
$ti->readFromSession();
$this->filter["title"] = $ti->getValue();
}
开发者ID:khanhnnvn,项目名称:ilias_E-learning,代码行数:16,代码来源:class.ilSurveyQuestionblockbrowserTableGUI.php
示例12: showPersonalData
function showPersonalData()
{
// user_id $this->user_obj->getId()
// all
$this->psc_obj = new ilPaymentShoppingCart($this->user_obj);
if (!count($items = $this->psc_obj->getEntries($this->pm_id))) {
$this->tpl->setVariable("HEADER", $this->lng->txt('pay_bmf_your_order'));
$this->tpl->touchBlock("stop_floating");
ilUtil::sendInfo($this->lng->txt('pay_shopping_cart_empty'));
} else {
$this->tpl->setVariable("HEADER", $this->lng->txt('pay_step1'));
$this->tpl->setVariable("TITLE", $this->lng->txt('pay_bmf_personal_data'));
$this->tpl->setVariable("DESCRIPTION", $this->lng->txt('pay_bmf_description_personal_data'));
$this->tpl->addBlockfile('ADM_CONTENT', 'adm_content', 'tpl.main_view.html', 'Services/Payment');
$oForm = new ilPropertyFormGUI();
$oForm->setFormAction($this->ctrl->getFormAction($this, 'getPersonalData'));
$oForm->setTitle($this->lng->txt('pay_bmf_personal_data'));
$oFirstname = new ilNonEditableValueGUI($this->lng->txt('firstname'));
$oFirstname->setValue($this->user_obj->getFirstname());
$oForm->addItem($oFirstname);
$oLastname = new ilNonEditableValueGUI($this->lng->txt('lastname'));
$oLastname->setValue($this->user_obj->getLastname());
$oForm->addItem($oLastname);
$oStreet = new ilTextInputGUI($this->lng->txt('street'), 'street');
$oStreet->setValue($this->error != '' && isset($_POST['street']) ? ilUtil::prepareFormOutput($_POST['street'], true) : ilUtil::prepareFormOutput($_SESSION['bmf']['personal_data']['street'], true));
$oForm->addItem($oStreet);
$oHouseNumber = new ilTextInputGUI($this->lng->txt('pay_bmf_house_number'), 'house_number');
$oHouseNumber->setValue($this->error != '' && isset($_POST['house_number']) ? ilUtil::prepareFormOutput($_POST['house_number'], true) : ilUtil::prepareFormOutput($_SESSION['bmf']['personal_data']['house_number'], true));
$oForm->addItem($oHouseNumber);
$oPoBox = new ilTextInputGUI($this->lng->txt('pay_bmf_or') . ' ' . $this->lng->txt('pay_bmf_po_box'), 'po_box');
$oPoBox->setValue($this->error != '' && isset($_POST['po_box']) ? ilUtil::prepareFormOutput($_POST['po_box'], true) : ilUtil::prepareFormOutput($_SESSION['bmf']['personal_data']['po_box'], true));
$oForm->addItem($oPoBox);
$oZipCode = new ilTextInputGUI($this->lng->txt('zipcode'), 'zipcode');
$oZipCode->setValue($this->error != '' && isset($_POST['zipcode']) ? ilUtil::prepareFormOutput($_POST['zipcode'], true) : ilUtil::prepareFormOutput($_SESSION['bmf']['personal_data']['zipcode'], true));
$oForm->addItem($oZipCode);
$oCity = new ilTextInputGUI($this->lng->txt('city'), 'city');
$oCity->setValue($this->error != '' && isset($_POST['city']) ? ilUtil::prepareFormOutput($_POST['city'], true) : ilUtil::prepareFormOutput($_SESSION['bmf']['personal_data']['city'], true));
$oForm->addItem($oCity);
$oCountry = new ilSelectInputGUI($this->lng->txt('country'), 'country');
$oCountry->setOptions($this->__getCountries());
$oCountry->setValue($this->error != '' && isset($_POST['country']) ? $_POST['country'] : $_SESSION['bmf']['personal_data']['country']);
$oForm->addItem($oCountry);
$oEmail = new ilNonEditableValueGUI($this->lng->txt('email'));
$oEmail->setValue($this->user_obj->getEmail());
$oForm->addItem($oEmail);
$oForm->addcommandButton('getPersonalData', ucfirst($this->lng->txt('next')));
$this->tpl->setVariable('FORM', $oForm->getHTML());
}
}
开发者ID:Walid-Synakene,项目名称:ilias,代码行数:49,代码来源:class.ilPurchaseBMFGUI.php
示例13: create
/**
* structure / page object creation form
*/
function create()
{
$new_type = $_REQUEST["new_type"];
$this->ctrl->setParameter($this, "new_type", $new_type);
include_once "Services/Form/classes/class.ilPropertyFormGUI.php";
$form = new ilPropertyFormGUI();
$form->setFormAction($this->ctrl->getFormAction($this, "save"));
$form->setTitle($this->lng->txt($new_type . "_new"));
$title = new ilTextInputGUI($this->lng->txt("title"), "Fobject[title]");
$title->setRequired(true);
$form->addItem($title);
$desc = new ilTextAreaInputGUI($this->lng->txt("description"), "Fobject[desc]");
$form->addItem($desc);
$form->addCommandButton("save", $this->lng->txt($new_type . "_add"));
$form->addCommandButton("cancel", $this->lng->txt("cancel"));
$this->tpl->setContent($form->getHTML());
}
开发者ID:Walid-Synakene,项目名称:ilias,代码行数:20,代码来源:class.ilLMObjectGUI.php
示例14: initPluginCreationFormSection
/**
* @param ilRadioOption $option
*/
public function initPluginCreationFormSection(ilRadioOption $option)
{
// $option->setInfo($this->txt('create_info1') . '</br>' . $this->txt('create_info2') . $this->getAdminConfigObject()->getAppName()
// . $this->txt('create_info3'));
$sub_selection = new ilRadioGroupInputGUI($this->txt(self::F_BASE_FOLDER), self::F_BASE_FOLDER);
$sub_selection->setRequired(true);
$option_default = new ilRadioOption($this->txt(self::F_DEFAULT_BASE_FOLDER), self::F_DEFAULT_BASE_FOLDER);
$option_custom = new ilRadioOption($this->txt('custom_base_folder'), self::F_CUSTOM_FOLDER_SELECTION);
$custom_base_folder_input = new ilTextInputGUI($this->txt(self::F_CUSTOM_BASE_FOLDER_INPUT), self::F_CUSTOM_BASE_FOLDER_INPUT);
$custom_base_folder_input->setRequired(true);
$custom_base_folder_input->setInfo($this->txt('custom_base_folder_input_info'));
$option_custom->addSubItem($custom_base_folder_input);
$sub_selection->addOption($option_default);
$sub_selection->addOption($option_custom);
$sub_selection->setValue(self::F_DEFAULT_BASE_FOLDER);
$option->addSubItem($sub_selection);
}
开发者ID:pschmitt77,项目名称:OneDrive,代码行数:20,代码来源:class.ilOneDriveCreationGUI.php
示例15: initFormRoleTemplate
/**
* Init create form
* @param bool creation mode
* @return ilPropertyFormGUI $form
*/
protected function initFormRoleTemplate($a_mode = self::FORM_MODE_CREATE)
{
include_once './Services/Form/classes/class.ilPropertyFormGUI.php';
$form = new ilPropertyFormGUI();
if ($this->creation_mode) {
$this->ctrl->setParameter($this, "new_type", 'rolt');
}
$form->setFormAction($this->ctrl->getFormAction($this));
if ($a_mode == self::FORM_MODE_CREATE) {
$form->setTitle($this->lng->txt('rolt_new'));
$form->addCommandButton('save', $this->lng->txt('rolt_new'));
} else {
$form->setTitle($this->lng->txt('rolt_edit'));
$form->addCommandButton('update', $this->lng->txt('save'));
}
$form->addCommandButton('cancel', $this->lng->txt('cancel'));
$title = new ilTextInputGUI($this->lng->txt('title'), 'title');
if ($a_mode != self::FORM_MODE_CREATE) {
if ($this->object->isInternalTemplate()) {
$title->setDisabled(true);
}
$title->setValue($this->object->getTitle());
}
$title->setSize(40);
$title->setMaxLength(70);
$title->setRequired(true);
$form->addItem($title);
$desc = new ilTextAreaInputGUI($this->lng->txt('description'), 'desc');
if ($a_mode != self::FORM_MODE_CREATE) {
$desc->setValue($this->object->getDescription());
}
$desc->setCols(40);
$desc->setRows(3);
$form->addItem($desc);
if ($a_mode != self::FORM_MODE_CREATE) {
$ilias_id = new ilNonEditableValueGUI($this->lng->txt("ilias_id"), "ilias_id");
$ilias_id->setValue('il_' . IL_INST_ID . '_' . ilObject::_lookupType($this->object->getId()) . '_' . $this->object->getId());
$form->addItem($ilias_id);
}
$pro = new ilCheckboxInputGUI($this->lng->txt('role_protect_permissions'), 'protected');
$pro->setChecked($GLOBALS['rbacreview']->isProtected($this->rolf_ref_id, $this->object->getId()));
$pro->setValue(1);
$form->addItem($pro);
return $form;
}
开发者ID:arlendotcn,项目名称:ilias,代码行数:50,代码来源:class.ilObjRoleTemplateGUI.php
示例16: initCreateFolder
/**
* Init form.
*
* @param int $a_mode Edit Mode
*/
public function initCreateFolder()
{
global $ilCtrl, $lng;
include_once "./Services/Form/classes/class.ilPropertyFormGUI.php";
$this->form = new ilPropertyFormGUI();
$this->form->setId("cld_create_folder");
$name = new ilTextInputGUI($lng->txt("cld_folder_name"), "folder_name");
$name->setRequired(true);
$this->form->addItem($name);
// folder id
$id = new ilHiddenInputGUI("parent_folder_id");
$id->setValue($_POST["id"]);
$this->form->addItem($id);
$this->form->addCommandButton("createFolder", $lng->txt("cld_create_folder"));
$this->form->addCommandButton("cancel", $lng->txt("cancel"));
$this->form->setTitle($lng->txt("cld_create_folder"));
$this->form->setFormAction($ilCtrl->getFormAction($this));
$this->form->setTarget("cld_blank_target");
}
开发者ID:arlendotcn,项目名称:ilias,代码行数:24,代码来源:class.ilCloudPluginCreateFolderGUI.php
示例17: initConfigurationForm
/**
* Init configuration form.
*
* @return object form object
*/
public function initConfigurationForm()
{
global $lng, $ilCtrl;
$pl = $this->getPluginObject();
include_once "Services/Form/classes/class.ilPropertyFormGUI.php";
$form = new ilPropertyFormGUI();
// setting 1 (a checkbox)
$cb = new ilCheckboxInputGUI($pl->txt("setting_1"), "setting_1");
$form->addItem($cb);
// setting 2 (text)
$ti = new ilTextInputGUI($pl->txt("setting_2"), "setting_2");
$ti->setRequired(true);
$ti->setMaxLength(10);
$ti->setSize(10);
$form->addItem($ti);
$form->addCommandButton("save", $lng->txt("save"));
$form->setTitle($pl->txt("example_plugin_configuration"));
$form->setFormAction($ilCtrl->getFormAction($this));
return $form;
}
开发者ID:prante,项目名称:CoreEmailSubscription,代码行数:25,代码来源:class.ilUIExampleConfigGUI.php
示例18: initFilter
/**
* Init filter
*/
public function initFilter()
{
global $lng;
$this->setDisableFilterHiding(true);
// object type selection
include_once "./Services/Form/classes/class.ilSelectInputGUI.php";
$si = new ilSelectInputGUI($lng->txt("obj_type"), "type");
$si->setOptions($this->getPossibleTypes(true, false, true));
$this->addFilterItem($si);
$si->readFromSession();
if (!$si->getValue()) {
$si->setValue("crs");
}
$this->filter["type"] = $si->getValue();
// title/description
include_once "./Services/Form/classes/class.ilTextInputGUI.php";
$ti = new ilTextInputGUI($lng->txt("trac_title_description"), "query");
$ti->setMaxLength(64);
$ti->setSize(20);
$this->addFilterItem($ti);
$ti->readFromSession();
$this->filter["query"] = $ti->getValue();
// read_count/spent_seconds
$si = new ilSelectInputGUI($lng->txt("trac_figure"), "figure");
$si->setOptions(array("read_count" => $lng->txt("trac_read_count"), "spent_seconds" => $lng->txt("trac_spent_seconds")));
$this->addFilterItem($si);
$si->readFromSession();
if (!$si->getValue()) {
$si->setValue("read_count");
}
$this->filter["measure"] = $si->getValue();
// year/month
$si = new ilSelectInputGUI($lng->txt("year") . " / " . $lng->txt("month"), "yearmonth");
$si->setOptions($this->getMonthsFilter());
$this->addFilterItem($si);
$si->readFromSession();
if (!$si->getValue()) {
$si->setValue(date("Y-m"));
}
$this->filter["yearmonth"] = $si->getValue();
}
开发者ID:Walid-Synakene,项目名称:ilias,代码行数:44,代码来源:class.ilLPObjectStatisticsDailyTableGUI.php
示例19: initPluginCreationFormSection
/**
* @param ilRadioOption $option
* @throws ilCloudPluginConfigException
*/
public function initPluginCreationFormSection(ilRadioOption $option)
{
$option->setInfo($this->txt("create_info1") . "</br>" . $this->txt("create_info2") . $this->getAdminConfigObject()->getAppName() . $this->txt("create_info3"));
$sub_selection = new ilRadioGroupInputGUI($this->txt(self::F_BASE_FOLDER), "dropbox_base_folder");
$sub_selection->setRequired(true);
$option_default = new ilRadioOption($this->txt("default_base_folder"), self::F_DROPBOX_DEFAULT_BASE_FOLDER);
$option_custom = new ilRadioOption($this->txt("custom_base_folder"), self::F_DROPBOX_CUSTOM_FOLDER_SELECTION);
$custom_base_folder_input = new ilTextInputGUI($this->txt("custom_base_folder_input"), self::F_DROPBOX_CUSTOM_BASE_FOLDER_INPUT);
$custom_base_folder_input->setRequired(true);
$custom_base_folder_input->setInfo($this->txt("custom_base_folder_input_info"));
$option_custom->addSubItem($custom_base_folder_input);
$sub_selection->addOption($option_default);
$sub_selection->addOption($option_custom);
$sub_selection->setValue(self::F_DROPBOX_DEFAULT_BASE_FOLDER);
$option->addSubItem($sub_selection);
$sub_selection2 = new ilCheckboxInputGUI($this->txt(self::F_ONLINE), self::F_ONLINE);
if ($this->getAdminConfigObject()->getValue('config_default_online')) {
$sub_selection2->setChecked(true);
}
$option->addSubItem($sub_selection2);
}
开发者ID:studer-raimann,项目名称:Dropbox,代码行数:25,代码来源:class.ilDropboxCreationGUI.php
示例20: initConfigurationForm
/**
* Init configuration form.
*
* @return object form object
*/
public function initConfigurationForm()
{
global $lng, $ilCtrl;
$pl = $this->getPluginObject();
include_once "Services/Form/classes/class.ilPropertyFormGUI.php";
$form = new ilPropertyFormGUI();
// Setting for the ephorus logging
$ephorus_logging = new ilCheckboxInputGUI($pl->txt("ephorus_logging"), "ephorus_logging");
$ephorus_logging->setValue(1);
$ephorus_logging->setInfo($pl->txt("ephorus_logging_description"));
$form->addItem($ephorus_logging);
// Setting for the hand-in code
$handin_code = new ilTextInputGUI($pl->txt("handin_code"), "handin_code");
$handin_code->setRequired(true);
$form->addItem($handin_code);
// Setting for the hand-in address
$handin_address = new ilTextInputGUI($pl->txt("handin_address"), "handin_address");
$handin_address->setSize(80);
$handin_address->setRequired(true);
$form->addItem($handin_address);
// Setting for the index address
$index_address = new ilTextInputGUI($pl->txt("index_address"), "index_address");
$index_address->setSize(80);
$index_address->setRequired(true);
$form->addItem($index_address);
// Setting for the processtype
$processtype = new ilSelectInputGUI($pl->txt("default_processtype"), "processtype");
$processtype->setOptions(array(1 => $pl->txt("default"), 3 => $pl->txt("private")));
$processtype->setInfo($pl->txt("default_processtype_description"));
$form->addItem($processtype);
// Setting for the disclosure
$disclosure = new ilTextAreaInputGUI($pl->txt("disclosure"), "disclosure");
$disclosure->setCols(79);
$disclosure->setRows(4);
$form->addItem($disclosure);
$form->addCommandButton("save", $lng->txt("save") . " / " . $pl->txt("check_connection"));
$form->setTitle($pl->txt("ephorus_plugin_configuration"));
$form->setFormAction($ilCtrl->getFormAction($this));
return $form;
}
开发者ID:jmcgettrick,项目名称:ilias-ephorus,代码行数:45,代码来源:class.ilEphorusConfigGUI.php
注:本文中的ilTextInputGUI类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论