Stud.IP  5.4
SidebarWidget Class Reference
Inheritance diagram for SidebarWidget:
Widget ClipboardWidget DateSelectWidget ListWidget ResourceTreeWidget RoomSearchWidget SearchWidget SelectWidget TemplateWidget

Public Member Functions

 __construct ()
 setId (string $id)
 getId ()
 setTitle ($title)
 getTitle ()
 removeTitle ()
 setExtra ($extra)
 getExtra ()
 removeExtra ()
 setAdditionalAttribute (string $key, $value)
 setAdditionalAttributes (array $attributes)
 removeAdditionalAttribute (string $key)
 render ($variables=[])
- Public Member Functions inherited from Widget
 addElement (WidgetElement $element, $index=null)
 insertElement (WidgetElement $element, $before_index, $index=null)
 getElement ($index)
 getElements ()
 removeElement ($index)
 hasElements ()
 hasElement ($index)
 forceRendering ($state=true)
 addLayoutCSSClass ($css_class)
 removeLayoutCSSClass ($css_class)
 render ($variables=[])
 __isset ($offset)
 __get ($offset)
 __set ($offset, $value)
 __unset ($offset)

Protected Attributes

 $additional_attributes = []
- Protected Attributes inherited from Widget
 $elements = []
 $template = 'widgets/widget'
 $template_variables = []
 $layout = 'widgets/widget-layout'
 $forced_rendering = false
 $layout_css_classes = []

Additional Inherited Members

- Protected Member Functions inherited from Widget
 guessIndex (WidgetElement $element)

Detailed Description

A widget for the sidebar.

Jan-Hendrik Willms GPL 2 or later
See also

Constructor & Destructor Documentation

◆ __construct()

__construct ( )

Member Function Documentation

◆ getExtra()

getExtra ( )

◆ getId()

getId ( )

Returns the ID of this widget, if it is set.

string The ID of the widget or an empty string, if it is not set.

◆ getTitle()

getTitle ( )

Returns the title of the widget

string The title of the widget of false if no title has been set

◆ removeAdditionalAttribute()

removeAdditionalAttribute ( string  $key)

◆ removeExtra()

removeExtra ( )

◆ removeTitle()

removeTitle ( )

Removes the title of the widget.

◆ render()

render (   $variables = [])

Renders the widget. The widget will only be rendered if it contains at least one element.

string The THML code of the rendered sidebar widget

◆ setAdditionalAttribute()

setAdditionalAttribute ( string  $key,

◆ setAdditionalAttributes()

setAdditionalAttributes ( array  $attributes)

◆ setExtra()

setExtra (   $extra)

◆ setId()

setId ( string  $id)

Sets the ID of the HTML element that represents the widget.

string$idThe element-ID to be used for the widget.

◆ setTitle()

setTitle (   $title)

Sets the title of the widget.

string$titleThe title of the widget

Field Documentation

◆ $additional_attributes

$additional_attributes = []

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