ILIAS  eassessment Revision 61809
 All Data Structures Namespaces Files Functions Variables Groups Pages
ilCustomInputGUI Class Reference

This class represents a custom property in a property form. More...

+ Inheritance diagram for ilCustomInputGUI:
+ Collaboration diagram for ilCustomInputGUI:

Public Member Functions

 __construct ($a_title="", $a_postvar="")
 Constructor.
 setHtml ($a_html)
 Set Html.
 getHtml ()
 Get Html.
 setValueByArray ($a_values)
 Set value by array.
 insert (&$a_tpl)
 Insert property html.
 checkInput ()
 Check input, strip slashes etc.
- Public Member Functions inherited from ilSubEnabledFormPropertyGUI
 addSubItem ($a_item)
 Add Subitem.
 getSubItems ()
 Get Subitems.
 checkSubItemsInput ()
 Check SubItems.
 getSubForm ()
 Get sub form html.
 getItemByPostVar ($a_post_var)
 Get item by post var.
- Public Member Functions inherited from ilFormPropertyGUI
executeCommand ()
 Execute command.
 getType ()
 Get Type.
 setTitle ($a_title)
 Set Title.
 getTitle ()
 Get Title.
 setPostVar ($a_postvar)
 Set Post Variable.
 getPostVar ()
 Get Post Variable.
 getFieldId ()
 Get Post Variable.
 setInfo ($a_info)
 Set Information Text.
 getInfo ()
 Get Information Text.
 setAlert ($a_alert)
 Set Alert Text.
 getAlert ()
 Get Alert Text.
 setRequired ($a_required)
 Set Required.
 getRequired ()
 Get Required.
 setDisabled ($a_disabled)
 Set Disabled.
 getDisabled ()
 Get Disabled.
 setParentForm ($a_parentform)
 Set Parent Form.
 getParentForm ()
 Get Parent Form.
 setParent ($a_val)
 Set Parent GUI object.
 getParent ()
 Get Parent GUI object.
 hideSubForm ()
 Sub form hidden on init?
 setHiddenTitle ($a_val)
 Set hidden title (for screenreaders)
 getHiddenTitle ()
 Get hidden title.
 serializeData ()
 serialize data
 unserializeData ($a_data)
 unserialize data
 writeToSession ()
 Write to session.
 clearFromSession ()
 Clear session value.
 readFromSession ()
 Read from session.
 getHiddenTag ($a_post_var, $a_value)
 Get hidden tag (used for disabled properties)

Protected Attributes

 $html
- Protected Attributes inherited from ilSubEnabledFormPropertyGUI
 $sub_items = array()
- Protected Attributes inherited from ilFormPropertyGUI
 $type
 $title
 $postvar
 $info
 $alert
 $required = false
 $parentgui
 $parentform
 $hidden_title = ""

Additional Inherited Members

- Protected Member Functions inherited from ilFormPropertyGUI
 setType ($a_type)
 Set Type.

Detailed Description

This class represents a custom property in a property form.

Author
Alex Killing alex..nosp@m.kill.nosp@m.ing@g.nosp@m.mx.d.nosp@m.e
Version
$Id$

Definition at line 31 of file class.ilCustomInputGUI.php.

Constructor & Destructor Documentation

ilCustomInputGUI::__construct (   $a_title = "",
  $a_postvar = "" 
)

Constructor.

Parameters
string$a_titleTitle
string$a_postvarPost Variable

Reimplemented from ilFormPropertyGUI.

Reimplemented in ilRecurrenceInputGUI, and ilAdditionalCharactersGUI.

Definition at line 41 of file class.ilCustomInputGUI.php.

References ilFormPropertyGUI\setType().

{
parent::__construct($a_title, $a_postvar);
$this->setType("custom");
}

+ Here is the call graph for this function:

Member Function Documentation

ilCustomInputGUI::checkInput ( )

Check input, strip slashes etc.

set alert, if input is not ok.

Returns
boolean Input ok, true/false

Reimplemented from ilFormPropertyGUI.

Reimplemented in ilRecurrenceInputGUI, and ilSolutionTitleInputGUI.

Definition at line 96 of file class.ilCustomInputGUI.php.

References $_POST, $lng, ilSubEnabledFormPropertyGUI\checkSubItemsInput(), ilFormPropertyGUI\getPostVar(), ilFormPropertyGUI\getRequired(), ilFormPropertyGUI\setAlert(), and ilUtil\stripSlashes().

{
global $lng;
if ($this->getRequired() && trim($_POST[$this->getPostVar()]) == "")
{
$this->setAlert($lng->txt("msg_input_is_required"));
return false;
}
return $this->checkSubItemsInput();
}

+ Here is the call graph for this function:

ilCustomInputGUI::getHtml ( )

Get Html.

Returns
string Html

Definition at line 62 of file class.ilCustomInputGUI.php.

References $html.

Referenced by insert().

{
return $this->html;
}

+ Here is the caller graph for this function:

ilCustomInputGUI::insert ( $a_tpl)

Insert property html.

Definition at line 84 of file class.ilCustomInputGUI.php.

References getHtml().

{
$a_tpl->setCurrentBlock("prop_custom");
$a_tpl->setVariable("CUSTOM_CONTENT", $this->getHtml());
$a_tpl->parseCurrentBlock();
}

+ Here is the call graph for this function:

ilCustomInputGUI::setValueByArray (   $a_values)

Set value by array.

Parameters
object$a_itemItem

Definition at line 72 of file class.ilCustomInputGUI.php.

References ilSubEnabledFormPropertyGUI\getSubItems().

{
foreach($this->getSubItems() as $item)
{
$item->setValueByArray($a_values);
}
}

+ Here is the call graph for this function:

Field Documentation

ilCustomInputGUI::$html
protected

Definition at line 33 of file class.ilCustomInputGUI.php.

Referenced by ilAdditionalCharactersGUI\__construct(), and getHtml().


The documentation for this class was generated from the following file: