Esempio n. 1
0
 /**
  * Constructs a new dropdown list object.
  *
  * @param string name The name of the dropdown list.
  * @param string value The initial selected item.
  * @param array items List of items to choose from
  * @param string caption The caption to display by the dropdown list.
  * @param bool multiple Dropdown list allows multiple selection.
  */
 function input_dropdown($name, $value = NULL, $items = NULL, $caption = NULL, $multiple = FALSE)
 {
     $this->items = $items;
     $this->caption = $caption;
     $this->multiple = $multiple;
     parent::input_base($name, NULL, $value);
 }
Esempio n. 2
0
 /**
  * Constructs a new radio group.
  *
  * @param string name The name of the radio.
  * @param int value The initial value.
  * @param array buttons The buttons in the radio object.
  */
 function input_radio($name, $value = NULL, $buttons = NULL)
 {
     $this->buttons = $buttons;
     parent::input_base($name, NULL, $value);
 }
 /**
  * Constructs a new querystring object.
  *
  * @param string name The name of the querystring object.
  * @param string regex The validation regular expression.
  * @param string value The initial contents value.
  */
 function input_querystring($name, $regex = NULL, $value = NULL)
 {
     parent::input_base($name, $regex, $value, FALSE, SQ_GET);
 }
Esempio n. 4
0
 /**
  * Constructs a new cookie object.
  *
  * @param string name The name of the querystring object.
  * @param string regex The validation regular expression.
  * @param string value The initial contents value.
  * @param int expire How long til the cookie expires in seconds.
  * @param string path The path the cookie is valid for.
  * @param string domain The domain the cookie is valid for.
  * @param bool secure Whether the cookie should only be sent over secure HTTP.
  */
 function input_cookie($name, $regex = NULL, $value = NULL, $expire = COOKIE_EXPIRE, $path = COOKIE_PATH, $domain = COOKIE_DOMAIN, $secure = COOKIE_SECURE)
 {
     parent::input_base($name, $regex, $value, FALSE, SQ_COOKIE);
     $this->expire = $expire;
     $this->path = $path;
     $this->domain = $domain;
     $this->secure = $secure;
 }
Esempio n. 5
0
 /**
  * Constructs a new textbox object.
  *
  * @param string name The name of the textbox.
  * @param string regex The validation regular expression.
  * @param string value The initial contents value.
  * @param string caption The caption to display by the textbox.
  * @param bool required Whether the texbox is allowed to contain no value.
  */
 function input_textbox($name, $regex = NULL, $value = NULL, $caption = NULL, $required = TRUE)
 {
     $this->type = 'text';
     $this->caption = $caption;
     parent::input_base($name, $regex, $value, $required);
 }