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


Code Type: 

Code Scope of Action: 

Code First Added: 

Code Altered: 

 Export Mark-up   [other codes of this type]

 document   [codes with similar scope]




Returns the relative path from the current notes's exported file to the directory that contains the cover page. The relative paths generated will still work during internal preview (i.e. without any export being generated).

When concatenating ^root^ with a path, do not add a trailing (folder) slash as this is created as part of the ^root^ output. Thus use:


…and not…

^root^/images/icon.gif WRONG!

Note that this is not necessarily the same as ^root(this)^, used in the case where a note (this) is embedded inside another note that is included in a page.

The ^root^ of this file's source note is: ../../../ (see your web browser's URL bar to see how this resolves in overall URL terms.).

For additional finer control of relative path calculation, consider use of ^setRoot()^.