Function __global->cns_get_default_poll_options

Definitions

sources/cns_polls_action3.php

  • Get default poll options for a specified forum.
  • Visibility: public
  • Is abstract?: No
  • Is static?: No
  • Is final?: No
  • Returns: array

Parameters

Name Type Passed by reference? Variadic? Default Set Range Description
$forum_id ?AUTO_LINK No No Null N/A N/A The ID of the forum for which we are getting default poll options (null: private topic)

Returns

  • Map of default poll options [options=>[[name=>string, mandatory=>boolean]], attribute=>value]
  • Type: array
  • Set: N/A
  • Range: N/A

Preview

Code (PHP)

/**
 * Get default poll options for a specified forum.
 *
 * @param  ?AUTO_LINK $forum_id The ID of the forum for which we are getting default poll options (null: private topic)
 * @return array Map of default poll options [options=>[[name=>string, mandatory=>boolean]], attribute=>value]
 */

function cns_get_default_poll_options(?int $forum_id = null) : array