Class SquirrelOption

Description

SquirrelOption: An option for Squirrelmail.

This class is a work in progress. When complete, it will handle presentation and saving of Squirrelmail user options in a simple, streamline manner. Stay tuned for more stuff.

Also, I'd like to ask that people leave this alone (mostly :) until I get it a little further along. That should only be a day or two or three. I will remove this message when it is ready for primetime usage.

Located in /functions/options.php (line 72)


	
			
Variable Summary
Method Summary
SquirrelOption SquirrelOption ( $raw_option_array,  $name,  $caption,  $type,  $refresh_level, [ $initial_value = ''], [ $possible_values = ''], [ $htmlencoded = false])
void changed ()
string createWidget_Boolean ([boolean $checkbox = TRUE])
string createWidget_FolderList ([boolean $multiple_select = FALSE])
string createWidget_String ([boolean $password = FALSE])
string createWidget_StrList ([boolean $multiple_select = FALSE], [boolean $radio_buttons = FALSE])
void save ()
void setCaptionWrap ( $caption_wrap)
void setComment ( $comment)
void setLayoutType ( $layout_type)
void setNewValue ( $new_value)
void setNoText ( $no_text)
void setPossValueFolders ( $poss_value_folders)
void setPostScript ( $post_script)
void setSaveFunction ( $save_function)
void setScript ( $script)
void setSize ( $size)
void setTrailingText ( $trailing_text)
void setUseAddWidget ( $use_add_widget)
void setUseDeleteWidget ( $use_delete_widget)
void setValue ( $value)
void setYesText ( $yes_text)
Variables
mixed $caption (line 76)
mixed $caption_wrap (line 77)
mixed $comment (line 82)
mixed $htmlencoded = false (line 99)
mixed $layout_type (line 81)
mixed $name (line 75)
mixed $new_value (line 97)
mixed $no_text (line 87)
mixed $possible_values (line 98)
mixed $poss_value_folders (line 90)
mixed $post_script (line 84)
mixed $raw_option_array (line 74)
mixed $refresh_level (line 79)
mixed $save_function (line 93)
mixed $script (line 83)
mixed $size (line 80)
mixed $trailing_text (line 85)
mixed $type (line 78)
mixed $use_add_widget (line 88)
mixed $use_delete_widget (line 89)
mixed $value (line 96)
mixed $yes_text (line 86)
Methods
Constructor SquirrelOption (line 101)
SquirrelOption SquirrelOption ( $raw_option_array,  $name,  $caption,  $type,  $refresh_level, [ $initial_value = ''], [ $possible_values = ''], [ $htmlencoded = false])
  • $raw_option_array
  • $name
  • $caption
  • $type
  • $refresh_level
  • $initial_value
  • $possible_values
  • $htmlencoded
changed (line 1140)
void changed ()
createHTMLWidget (line 235)
void createHTMLWidget ()
createWidget_Boolean (line 628)

Create boolean widget

When creating Yes/No radio buttons, the "yes_text" and "no_text" option attributes are used to override the typical "Yes" and "No" text.

  • return: html formated boolean widget
string createWidget_Boolean ([boolean $checkbox = TRUE])
  • boolean $checkbox: When TRUE, the widget will be constructed as a checkbox, otherwise it will be a set of Yes/No radio buttons (OPTIONAL; default is TRUE (checkbox)).
createWidget_Comment (line 679)
void createWidget_Comment ()
createWidget_EditList (line 694)

Creates a (non-associative) edit list

Note that multiple layout types are supported for this widget. $this->layout_type must be one of the SMOPT_EDIT_LIST_LAYOUT_* constants.

  • return: html formated list of edit fields and their associated controls
string createWidget_EditList ()
createWidget_EditListAssociative (line 862)

Creates an associative edit list

Note that multiple layout types are supported for this widget. $this->layout_type must be one of the SMOPT_EDIT_LIST_LAYOUT_* constants.

  • return: html formated list of edit fields and their associated controls
string createWidget_EditListAssociative ()
createWidget_Float (line 596)
void createWidget_Float ()
createWidget_FolderList (line 493)

Create folder selection box

  • return: html formated selection box
string createWidget_FolderList ([boolean $multiple_select = FALSE])
  • boolean $multiple_select: When TRUE, the select widget will allow multiple selections (OPTIONAL; default is FALSE (single select list))
createWidget_Hidden (line 672)
void createWidget_Hidden ()
createWidget_Info (line 321)
void createWidget_Info ()
createWidget_Integer (line 581)
void createWidget_Integer ()
createWidget_String (line 336)

Create text box

  • return: html formated text input
string createWidget_String ([boolean $password = FALSE])
  • boolean $password: When TRUE, the text in the input widget will be obscured (OPTIONAL; default = FALSE).
createWidget_StrList (line 391)

Create selection box or radio group

When $this->htmlencoded is TRUE, the keys and values in $this->possible_values are assumed to be display-safe. Use with care!

Note that when building radio buttons instead of a select widget, if the "size" attribute is SMOPT_SIZE_TINY, the radio buttons will be output one after another without linebreaks between them. Otherwise, each radio button goes on a line of its own.

  • return: html formated selection box or radio buttons
string createWidget_StrList ([boolean $multiple_select = FALSE], [boolean $radio_buttons = FALSE])
  • boolean $multiple_select: When TRUE, the select widget will allow multiple selections (OPTIONAL; default is FALSE (single select list))
  • boolean $radio_buttons: When TRUE, the widget will instead be built as a group of radio buttons (and $multiple_select will be forced to FALSE) (OPTIONAL; default is FALSE (select widget))
createWidget_Submit (line 1124)

Creates a submit button

  • return: html formated submit button widget
string createWidget_Submit ()
createWidget_TextArea (line 566)
void createWidget_TextArea ()
is_multiple_valued (line 151)

Convenience function that identifies which types of

void is_multiple_valued ()
save (line 1135)
void save ()
setCaptionWrap (line 169)
void setCaptionWrap ( $caption_wrap)
  • $caption_wrap
setComment (line 216)
void setComment ( $comment)
  • $comment
setLayoutType (line 211)
void setLayoutType ( $layout_type)
  • $layout_type
setNewValue (line 164)
void setNewValue ( $new_value)
  • $new_value
setNoText (line 189)
void setNoText ( $no_text)
  • $no_text
setPossValueFolders (line 206)
void setPossValueFolders ( $poss_value_folders)
  • $poss_value_folders
setPostScript (line 226)
void setPostScript ( $post_script)
  • $post_script
setSaveFunction (line 231)
void setSaveFunction ( $save_function)
  • $save_function
setScript (line 221)
void setScript ( $script)
  • $script
setSize (line 174)
void setSize ( $size)
  • $size
setTrailingText (line 179)
void setTrailingText ( $trailing_text)
  • $trailing_text
setUseAddWidget (line 194)
void setUseAddWidget ( $use_add_widget)
  • $use_add_widget
setUseDeleteWidget (line 199)
void setUseDeleteWidget ( $use_delete_widget)
  • $use_delete_widget
setValue (line 159)
void setValue ( $value)
  • $value
setYesText (line 184)
void setYesText ( $yes_text)
  • $yes_text

Documentation generated on Tue, 25 Nov 2014 04:21:32 +0100 by phpDocumentor 1.4.3