Ditto 2.1 placeholders
From MODx Wiki
Note that if using an id parameter in Ditto (&id=`myid`) then the placeholders must be prefixed by that id followed by underscore. For example [+myid_next+].
Contents |
General placeholders
- [+author+]
- Purpose: First available of createdby->fullname, createdby->username, admin username of retrieved document
- [+title+]
- Purpose: pagetitle field of retrieved document
- [+url+]
- Purpose: link to retrieved document
- [+ditto_iteration+]
- Purpose: sequence number of retrieved document within current page
- Notes: Starts from zero
- [+ditto_sort +]
- Purpose: sequence number of retrieved document within complete retrieved set
- Notes: Not officially documented, spotted in Debug screen and it just works. Starts from zero
Placeholders for pagination
- ALL PAGINATION PLACEHOLDERS ARE EMPTY if &paginate <> 1
- [+next+]
- Purpose: link to next page of result
- [+previous+]
- Purpose: link to previous page of result
- [+splitter+]
- Purpose: filled with &paginateSplitterCharacter when [+previous+] and [+next+] are both active
- [+start+]
- Purpose: sequence number within complete set of first displayed document on page
- [+urlStart+]
- Purpose: number of current page as seen in URL query string (?start=[+urlStart+])
- [+stop+]
- Purpose: sequence number within complete set of last displayed document on page
- [+total+]
- Purpose: total number of retrieved documents
- [+pages+]
- Purpose: page-number links to all the other pages, inactive display of current page number
- [+currentPage +]
- Purpose: number of current page
- [+perPage+]
- Purpose: displayed items per page (equal to <strong>&display</strong>)
- [+totalPages+]
- Purpose: total number of pages in result
- [+ditto_pagination_set+]
- Purpose: 1 if &paginate is set
Placeholders for summary
- [+content+]
- Purpose: Content of document content field, if not blank, or truncated text
- [+summary+]
- Purpose: Content of introtext field, if not blank, or truncated text
- [+link+]
- Purpose: Link to full item
- Notes: Link text set by &trunctText or default from language file
Placeholders for tagging
- [+tagLinks+]
- Purpose: list of tags associated with document, separated by &tagDelimiter
- Notes: Hyperlinks to filtered view for each tag in &tagDocumentID (or current document)
- [+tags+]
- Purpose: In page containing result: tags used to filter in the displayed documents
- Notes: Reflects &tags parameter or tags supplied in URL
Placeholders for dateFilter
- [+year+]
- Purpose: selected year in filter
- Notes: Two or four-digit value as supplied
- [+month+]
- Purpose: selected month in filter
- Notes: Numerical month
- [+day+]
- Purpose: selected day in filter
- Notes: Numerical day