Function __global->wiki_breadcrumbs
Definitions
sources/wiki.php
- Convert a Wiki+ chain to a nice breadcrumb trail.
- Visibility: public
- Is abstract?: No
- Is static?: No
- Is final?: No
- Returns: array
Parameters
| Name | Type | Passed by reference? | Variadic? | Default | Set | Range | Description |
|---|---|---|---|---|---|---|---|
| $chain | string | No | No | required parameter | N/A | N/A | The chain to convert (which should include the current page ID) |
| $current_title | ?string | No | No | Null | N/A | N/A | The title of the current Wiki+ page (if not given, it is looked up) (null: work it out) |
| $final_link | boolean | No | No | False | N/A | N/A | Whether to show the final breadcrumbs element with a link to it (all others will always have links if $links is true) |
| $links | boolean | No | No | True | N/A | N/A | Whether to show links to pages in the breadcrumbs |
| $this_link_virtual_root | boolean | No | No | False | N/A | N/A | Whether to make the link as a virtual-root link (only applies if $final_link is true) |
Returns
- Breadcrumbs
- Type: array
- Set: N/A
- Range: N/A
Preview
Code (PHP)
/**
* Convert a Wiki+ chain to a nice breadcrumb trail.
*
* @param string $chain The chain to convert (which should include the current page ID)
* @param ?string $current_title The title of the current Wiki+ page (if not given, it is looked up) (null: work it out)
* @param boolean $final_link Whether to show the final breadcrumbs element with a link to it (all others will always have links if $links is true)
* @param boolean $links Whether to show links to pages in the breadcrumbs
* @param boolean $this_link_virtual_root Whether to make the link as a virtual-root link (only applies if $final_link is true)
* @return array Breadcrumbs
*/
function wiki_breadcrumbs(string $chain, ?string $current_title = null, bool $final_link = false, bool $links = true, bool $this_link_virtual_root = false) : array
* Convert a Wiki+ chain to a nice breadcrumb trail.
*
* @param string $chain The chain to convert (which should include the current page ID)
* @param ?string $current_title The title of the current Wiki+ page (if not given, it is looked up) (null: work it out)
* @param boolean $final_link Whether to show the final breadcrumbs element with a link to it (all others will always have links if $links is true)
* @param boolean $links Whether to show links to pages in the breadcrumbs
* @param boolean $this_link_virtual_root Whether to make the link as a virtual-root link (only applies if $final_link is true)
* @return array Breadcrumbs
*/
function wiki_breadcrumbs(string $chain, ?string $current_title = null, bool $final_link = false, bool $links = true, bool $this_link_virtual_root = false) : array

