Function Forum_driver_cns->find_topic_id_for_topic_identifier
Definitions
sources/forum/cns.php
- Get the topic ID from a topic identifier in the specified forum. It is used by comment topics, which means that the unique-topic-name assumption holds valid.
- Visibility: public
- Is abstract?: No
- Is static?: No
- Is final?: No
- Returns: int
Parameters
Name | Type | Passed by reference? | Variadic? | Default | Set | Range | Description |
---|---|---|---|---|---|---|---|
$forum | string | No | No | required parameter | N/A | N/A | The forum name / ID |
$topic_identifier | SHORT_TEXT | No | No | required parameter | N/A | N/A | The topic identifier |
$topic_identifier_encapsulation_prefix | ?string | No | No | Null | N/A | N/A | This is put together with the topic identifier to make a more-human-readable topic title or topic description (hopefully the latter and a $content_title title, but only if the forum supports descriptions). Set this to improve performance (null: unknown) |
Returns
- The topic ID (null: not found)
- Type: ?integer
- Set: N/A
- Range: N/A
Preview
Code (PHP)
/**
* Get the topic ID from a topic identifier in the specified forum. It is used by comment topics, which means that the unique-topic-name assumption holds valid.
*
* @param string $forum The forum name / ID
* @param SHORT_TEXT $topic_identifier The topic identifier
* @param ?string $topic_identifier_encapsulation_prefix This is put together with the topic identifier to make a more-human-readable topic title or topic description (hopefully the latter and a $content_title title, but only if the forum supports descriptions). Set this to improve performance (null: unknown)
* @return ?integer The topic ID (null: not found)
*/
public function find_topic_id_for_topic_identifier(string $forum, string $topic_identifier, ?string $topic_identifier_encapsulation_prefix = null) : ?int
* Get the topic ID from a topic identifier in the specified forum. It is used by comment topics, which means that the unique-topic-name assumption holds valid.
*
* @param string $forum The forum name / ID
* @param SHORT_TEXT $topic_identifier The topic identifier
* @param ?string $topic_identifier_encapsulation_prefix This is put together with the topic identifier to make a more-human-readable topic title or topic description (hopefully the latter and a $content_title title, but only if the forum supports descriptions). Set this to improve performance (null: unknown)
* @return ?integer The topic ID (null: not found)
*/
public function find_topic_id_for_topic_identifier(string $forum, string $topic_identifier, ?string $topic_identifier_encapsulation_prefix = null) : ?int