This version is out of date, covering development from v9.0.0 to v9.3.0. It is maintained here only for inbound reference links from elsewhere. It is no longer actively updated.

Jump to the current version of aTbRef

Tinderbox v9 Icon

^childLinks( [start, list-item-prefix, list-item-suffix, end] )^


Code Type: 

Code Scope of Action: 

Code First Added: 

Code Altered: 

 Creation of Links   [other codes of this type]

 item   [codes with similar scope]

 Baseline

 format"


^childLinks( ["start", "list-item-prefix", "list-item-suffix", "end"] )^

returns links to all of the children of this note (if any), formatted as an unordered list. NB! If "Hierarchical lists" in the HTML pane of the preferences is unchecked, this will not work.

If the optional start, list-item-prefix, list-item-suffix, end parameters are omitted then the default values of <ul>, <li>, </li>, </ul> are used.

This allows you to format the group of links as an HTML list or table in the exact format you want, where "start" is text that will be inserted before all of the links, "end" is text that will be inserted after all of the links, "list-item-prefix" is text that will be inserted before each link, and "list-item-suffix" is text that will be inserted after each link. See more on altering list type or other HTML output.

Mark-up elements embedded in ^childLinks^ are evaluated.

If "Hierarchical lists" in the HTML pane of the preferences is unchecked, this will not work.

The HTMLDontExport settings of children are respected.

Usually, rules and queries to test whether a note has children will test ChildCount. But ^if(^childLinks^)… is better if you want the expression to be false if the note has children BUT none of the children are exported.

Exported links use the CSS class and target based on their underlying Tinderbox link values, if one is specified; the link type value is not picked up as a class name.

Item objects source and destination may be used in expressions to indicate from where data used within the expression's arguments is drawn.

If appears in a note (or its template) which does not export its own children, it instead creates links to the original of each child.

The export is relative to current rather than this, facilitating work with included files.



A Tinderbox Reference File : Export Codes : Export Codes - Full Listing : ^childLinks( [start, list-item-prefix, list-item-suffix, end] )^