Moodle PHP Documentation 4.5
Moodle 4.5.5+ (Build: 20250711) (ce34e8ff087)
mod_choice_renderer Class Reference
Inheritance diagram for mod_choice_renderer:

Public Member Functions

 display_options ($options, $coursemoduleid, $vertical=false, $multiple=false)
 Returns HTML to display choices of option.
 
 display_publish_anonymous ($choices, $displaylayout)
 Generate the choice result chart.
 
 display_publish_anonymous_horizontal ($choices)
 Returns HTML to display choices result.
 
 display_publish_anonymous_vertical ($choices)
 Returns HTML to display choices result.
 
 display_publish_name_vertical ($choices)
 Returns HTML to display choices result.
 
 display_result ($choices, $forcepublish=false)
 Returns HTML to display choices result.
 

Member Function Documentation

◆ display_options()

mod_choice_renderer::display_options ( $options,
$coursemoduleid,
$vertical = false,
$multiple = false )

Returns HTML to display choices of option.

Parameters
object$options
int$coursemoduleid
bool$vertical
Return values
string

◆ display_publish_anonymous()

mod_choice_renderer::display_publish_anonymous ( $choices,
$displaylayout )

Generate the choice result chart.

Can be displayed either in the vertical or horizontal position.

Parameters
stdClass$choicesChoices responses object.
int$displaylayoutThe constants CHOICE_DISPLAY_HORIZONTAL or CHOICE_DISPLAY_VERTICAL.
Return values
stringthe rendered chart.

◆ display_publish_anonymous_horizontal()

mod_choice_renderer::display_publish_anonymous_horizontal ( $choices)

Returns HTML to display choices result.

Deprecated
since 3.2
Parameters
object$choices
Return values
string

◆ display_publish_anonymous_vertical()

mod_choice_renderer::display_publish_anonymous_vertical ( $choices)

Returns HTML to display choices result.

Deprecated
since 3.2
Parameters
object$choices
Return values
string

◆ display_publish_name_vertical()

mod_choice_renderer::display_publish_name_vertical ( $choices)

Returns HTML to display choices result.

Parameters
object$choices
Return values
string

◆ display_result()

mod_choice_renderer::display_result ( $choices,
$forcepublish = false )

Returns HTML to display choices result.

Parameters
object$choices
bool$forcepublish
Return values
string

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