Function CMS_Topic->get_posting_form

Definitions

sources/topics.php

  • Get a form for posting.
  • Visibility: public
  • Is abstract?: No
  • Is static?: No
  • Is final?: No
  • Returns: object

Parameters

Name Type Passed by reference? Variadic? Default Set Range Description
$type ID_TEXT No No required parameter N/A N/A The content type of what this posting will be for
$id ID_TEXT No No required parameter N/A N/A The content ID of what this posting will be for
$allow_reviews boolean No No required parameter N/A N/A Whether to accept reviews
$post_url Tempcode No No required parameter N/A N/A URL where form submit will go
$post_warning ?string No No required parameter N/A N/A The default post to use (null: standard courtesy warning)
$hidden ?Tempcode No No Null N/A N/A Hidden form fields for commenting form (null: none)

Returns

  • Posting form
  • Type: Tempcode
  • Set: N/A
  • Range: N/A

Preview

Code (PHP)

/**
 * Get a form for posting.
 *
 * @param  ID_TEXT $type The content type of what this posting will be for
 * @param  ID_TEXT $id The content ID of what this posting will be for
 * @param  boolean $allow_reviews Whether to accept reviews
 * @param  Tempcode $post_url URL where form submit will go
 * @param  ?string $post_warning The default post to use (null: standard courtesy warning)
 * @param  ?Tempcode $hidden Hidden form fields for commenting form (null: none)
 * @return Tempcode Posting form
 */

public function get_posting_form(string $type, string $id, bool $allow_reviews, object $post_url, ?string $post_warning, ?object $hidden = null) : object