Display Tags
The display tags are the Dispatch tags that specifically relate to the fields in your publication's database, be it the headline, author, story or a user defined field. They are the most common of the Dispatch tags, and are primarily used to retrieve, manipulate and display information on a page.
<dpAuthor>
D E F I N I T I O N:
The author of the story currently being built or queried. By default <dpAuthor> will always return all of the authors of the story.
<dpAuthor
format="standard|initials|fmlast|firstlast|lastfirst|first|middle|last"
number="#|all"
return="value|count"
default="default text"
style="lower|upper|title|spaced|roman|decimal|identifier|
noHtml|noHtmlStyle|scriptEncode|uriEncode"
link="on|off|email|homepage"
start="#p|#s|#w|#c|begin|end|resume"
stop="#p|#s|#w|#c|begin|end|resume"
length="#p|#s|#w|#c|begin|end"
>
A T T R I B U T E S:
<dpAuthor format="standard"> - Kay Anne Sather
<dpAuthor format="initials"> - KAS
<dpAuthor format="fmlast"> - K A Sather
<dpAuthor format="firstlast"> - Kay Sather
<dpAuthor format="lastfirst"> - Sather, Kay
<dpAuthor format="first"> - Kay
<dpAuthor format="middle"> - Anne
<dpAuthor format="last"> - Sather
number="all" is the default and will always return all the authors of a story, be it one or many.
For example:
<dpIf <dpAuthor return="count"> = 1>
{do the regular author layout}
<dpElseIf <dpAuthor return="count"> gt 1>
{do the multi author layout and loop through the authors}
</dpIf>
The following expands on this concept and creates a link to the author's archive page. If there are multiple authors, it will create a link to each author's individual archive page by looping through them.
<dpIf <dpAuthor return="count"> = 1>
<dpAuthorCredit> <a href="../authors/<dpAuthorID>.html"><dpAuthor></a>
<dpElseIf <dpAuthor return="count"> gt 1>
<dpAuthorCredit>
<dpLoop var="i" from="1" to="<dpAuthor return="count">">
<a href="../authors/<dpAuthorID number="<dpVar i>">.html">
<dpAuthor number="<dpVar i>"></a>
<dpIf <dpVar i> lt <dpAuthor return="count">>
,
</dpIf>
</dpLoop>
</dpIf>
The idea is to loop through however many authors you have (from="1" to="<dpAuthor return="count">"), and then process each one individually, using the number attribute and the loop variable (<dpVar i>).
An additional test is performed to see if it is the last author or not. If it isn't a comma is displayed.
Please refer to the common attributes page for the common attribute descriptions.
E X A M P L E S:
|
<dpAuthor> |
Jeff Smith |
|
<dpAuthor link="email"> |
Jeff Smith |
|
<dpAuthor format="initials"> |
JS |
|
<dpIf <dpAuthor>> <i><dpAuthorCredit> <dpAuthor></i> </dpIf> |
By Jeff Smith |
<dpAuthorCredit>
D E F I N I T I O N:
Returns the credit type for the author, such as "By" or "Edited By".
<dpAuthorCredit
default="default text"
style="lower|upper|title|spaced|roman|decimal|identifier|
noHtml|noHtmlStyle|scriptEncode|uriEncode"
link="on|off"
start="#p|#s|#w|#c|begin|end|resume"
stop="#p|#s|#w|#c|begin|end|resume"
length="#p|#s|#w|#c|begin|end"
>
A T T R I B U T E S:
Please refer to the common attributes page for the common attribute descriptions.
E X A M P L E S:
<dpAuthorCredit> <dpAuthor>
would return: By Neil Gaiman
A more common use would be to test to see if the story has an author first:
<dpIf <dpAuthor>>
<dpAuthorCredit> <dpAuthor>
</dpIf>
<dpAuthorID>
D E F I N I T I O N:
The author ID of the story currently being built or queried. ID's are always in lowercase and contain no spaces. They are most commonly used to reference images or files.
<dpAuthorID
default="default text"
number="#"
return="value|count"
style="lower|upper|title|spaced|roman|decimal|identifier|
noHtml|noHtmlStyle|scriptEncode|uriEncode"
link="on|off"
start="#p|#s|#w|#c|begin|end|resume"
stop="#p|#s|#w|#c|begin|end|resume"
length="#p|#s|#w|#c|begin|end"
>
A T T R I B U T E S:
Please refer to the common attributes page for the common attribute descriptions.
E X A M P L E S:
|
<dpAuthorID> |
jeffsmith |
<dpColumn>
D E F I N I T I O N:
The column that the story belongs to which is currently being built or queried.
<dpColumn
default="default text"
style="lower|upper|title|spaced|roman|decimal|identifier|
noHtml|noHtmlStyle|scriptEncode|uriEncode"
link="on|off"
start="#p|#s|#w|#c|begin|end|resume"
stop="#p|#s|#w|#c|begin|end|resume"
length="#p|#s|#w|#c|begin|end"
>
A T T R I B U T E S:
Please refer to the common attributes page for the common attribute descriptions.
E X A M P L E S:
|
<dpColumn> |
Music Feature |
|
<dpColumn style="lower"> |
music feature |
|
You're viewing: <dpColumn> |
You're viewing: Music Feature |
<dpColumnID>
D E F I N I T I O N:
The column ID that the story belongs to which is currently being built or queried. ID's are always in lowercase and contain no spaces. They are most commonly used to reference image names or files.
<dpColumnID
default="default text"
style="lower|upper|title|spaced|roman|decimal|identifier|
noHtml|noHtmlStyle|scriptEncode|uriEncode"
link="on|off"
start="#p|#s|#w|#c|begin|end|resume"
stop="#p|#s|#w|#c|begin|end|resume"
length="#p|#s|#w|#c|begin|end"
>
A T T R I B U T E S:
Please refer to the common attributes page for the common attribute descriptions.
E X A M P L E S:
|
<dpColumnID> |
smith |
|
<dpIf <dpColumnID> = "smith"> You're reading smith! <dpElse> You should really check out <a href="smith.html">Smith</a>. </dpIf> |
You're reading smith! |
<dpFile>
D E F I N I T I O N:
The file name of the story currently being built or queried.
<dpFile
default="default text"
style="lower|upper|title|spaced|roman|decimal|identifier|
noHtml|noHtmlStyle|scriptEncode|uriEncode"
link="on|off"
start="#p|#s|#w|#c|begin|end|resume"
stop="#p|#s|#w|#c|begin|end|resume"
length="#p|#s|#w|#c|begin|end"
>
A T T R I B U T E S:
Please refer to the common attributes page for the common attribute descriptions.
E X A M P L E S:
|
<dpFile> |
smith.html |
<dpFileID>
D E F I N I T I O N:
The file ID of the story that is currently being built or queried. <dpFileID> always returns the base file name, as in "cinema" or "cinema4", whereas <dpFile> would return "cinema.html" or "cinema4.html".
<dpFileID
default="default text"
style="lower|upper|title|spaced|roman|decimal|identifier|
noHtml|noHtmlStyle|scriptEncode|uriEncode"
link="on|off"
start="#p|#s|#w|#c|begin|end|resume"
stop="#p|#s|#w|#c|begin|end|resume"
length="#p|#s|#w|#c|begin|end"
>
A T T R I B U T E S:
Please refer to the common attributes page for the common attribute descriptions.
E X A M P L E S:
|
<dpFileID> |
smith |
<dpHeadline>
D E F I N I T I O N:
The headline of the story currently being built or queried.
<dpHeadline
default="default text"
style="lower|upper|title|spaced|roman|decimal|identifier|
noHtml|noHtmlStyle|scriptEncode|uriEncode"
link="on|off"
start="#p|#s|#w|#c|begin|end|resume"
stop="#p|#s|#w|#c|begin|end|resume"
length="#p|#s|#w|#c|begin|end"
>
A T T R I B U T E S:
Please refer to the common attributes page for the common attribute descriptions.
E X A M P L E S:
|
<dpHeadline> |
All Fired Up |
|
<dpHeadline style="upper" style="spaced"> |
|
|
<b><dpHeadline link="on"></b><br> <dpSummary> |
All Fired Up The Steak-Out, home of the $30 steak with no potato, burned down a week ago last Saturday. |
<dpHeadlineDefault>
D E F I N I T I O N:
This tag will return the headline value you have set for this column's default headline.
<dpHeadlineDefault
default="default text"
style="lower|upper|title|spaced|roman|decimal|identifier|
noHtml|noHtmlStyle|scriptEncode|uriEncode"
link="on|off"
start="#p|#s|#w|#c|begin|end|resume"
stop="#p|#s|#w|#c|begin|end|resume"
length="#p|#s|#w|#c|begin|end"
>
A T T R I B U T E S:
Please refer to the common attributes page for the common attribute descriptions.
<dpIssue>
D E F I N I T I O N:
The issue of the story currently being built or queried. This is also the directory name of the issue.
<dpIssue
default="default text"
style="lower|upper|title|spaced|roman|decimal|identifier|
noHtml|noHtmlStyle|scriptEncode|uriEncode"
link="on|off"
start="#p|#s|#w|#c|begin|end|resume"
stop="#p|#s|#w|#c|begin|end|resume"
length="#p|#s|#w|#c|begin|end"
>
A T T R I B U T E S:
Please refer to the common attributes page for the common attribute descriptions.
E X A M P L E S:
|
<dpIssue> |
1998-06-25 |
|
<dpIssue style="roman"> |
MCMXCVIII-VI-XXV |
<dpIssueID>
D E F I N I T I O N:
The issue ID of the story currently being built or queried. ID's are always in lowercase and contain no spaces. They are most commonly used to reference image names.
<dpIssueID
default="default text"
style="lower|upper|title|spaced|roman|decimal|identifier|
noHtml|noHtmlStyle|scriptEncode|uriEncode"
link="on|off"
start="#p|#s|#w|#c|begin|end|resume"
stop="#p|#s|#w|#c|begin|end|resume"
length="#p|#s|#w|#c|begin|end"
>
A T T R I B U T E S:
Please refer to the common attributes page for the common attribute descriptions.
E X A M P L E S:
|
<dpIssueID> |
1998-06-25 |
<dpIssueDate>
D E F I N I T I O N:
The issue date of the issue currently being built or queried.
<dpIssueDate
begin="strftime()"
separator="default text"
end="strftime()"
default="default text"
style="lower|upper|title|spaced|roman|decimal|identifier|
noHtml|noHtmlStyle|scriptEncode|uriEncode"
link="on|off"
start="#p|#s|#w|#c|begin|end|resume"
stop="#p|#s|#w|#c|begin|end|resume"
length="#p|#s|#w|#c|begin|end"
>
The default format for <dpIssueDate> is: <dpIssueDate begin="%B %e - " begin="%B %e, %Y">, which returns a date in this format: "June 25 - July 1, 1999"
A T T R I B U T E S:
Please refer to the common attributes page for the common attribute descriptions.
strftime() values:
| Thursday | National representation of the full weekday name. | |
| Thu | National representation of the abbreviated weekday name, where the abbreviation is the first three characters. | |
| January | National representation of the full month name. | |
| Jan | National representation of the abbreviated month name, where the abbreviation is the first three characters. | |
| 01 | Month as a decimal number (01-12). | |
| 07 | Day of the month as a decimal number (01-31). | |
| 7 | Day of the month as a decimal number (1-31); single digits are preceded by a blank. | |
| 1998 | Year with century as a decimal number. | |
| 98 | Year without century as a decimal number (00-99). | |
| 01/07/98 | Equivalent to "%m/%d/%y". |
Additional strftime() values can be found here.
E X A M P L E S:
|
<dpIssueDate> |
June 25 - July 1, 1998 |
|
<dpIssueDate begin="%A" separator=" through " end="%A"> |
Thursday through Wednesday |
|
<dpIssueDate begin="%A through " end="%A"> |
Thursday through Wednesday |
|
<dpIssueDate begin="%B %e, %Y"> |
June 25, 1998 |
|
<dpIssueDate end="%B %e, %Y"> |
July 1, 1998 |
|
<dpIssueDate begin="%Y-%m-%d"> |
1998-06-25 |
|
<dpIssueDate begin="%B %e, %Y" style="upper"> |
JUNE 25, 1998 |
|
<dpIssueDate begin="%Y" style="roman"> |
MCMXCVIII |
<dpIssueNumber>
D E F I N I T I O N:
The issue number of the issue currently being built or queried.
<dpIssueNumber
default="default text"
style="lower|upper|title|spaced|roman|decimal|identifier|
noHtml|noHtmlStyle|scriptEncode|uriEncode"
link="on|off"
start="#p|#s|#w|#c|begin|end|resume"
stop="#p|#s|#w|#c|begin|end|resume"
length="#p|#s|#w|#c|begin|end"
>
A T T R I B U T E S:
Please refer to the common attributes page for the common attribute descriptions.
E X A M P L E S:
|
<dpIssueNumber> |
18 |
|
<dpIssueNumber style="roman"> |
XVIII |
|
<dpIssueNumber style="roman" style="lower"> |
xviii |
|
Volume <dpVolumeNumber> Issue <dpIssueNumber> |
Volume 15 Issue 18 |
<dpMetaDescription>
D E F I N I T I O N:
This tag will return the column's default meta description. You set this in column defaults.
<dpMetaDescription
default="default text"
style="lower|upper|title|spaced|roman|decimal|
noHtml|noHtmlStyle|identifier|scriptEncode"
link="on|off"
start="#p|#s|#w|#c|begin|end|resume"
stop="#p|#s|#w|#c|begin|end|resume"
length="#p|#s|#w|#c|begin|end"
>
A T T R I B U T E S:
Notice that style="noHtml" is the default for this tag. This will prevent potential HTML from side effecting meta tags.
Please refer to the common attributes page for the common attribute descriptions.
E X A M P L E S:
<meta name="description" content="<dpMetaDescription>">
or better yet, use the summary if it exists and then fall back (default=) to the meta description if no summary exists:
<meta name="description" content="<dpSummary style="noHTML" default="<dpMetaDescription>">">
<dpMetaKeywords>
D E F I N I T I O N:
This tag will return the column's default meta keywords. You set this in column defaults.
<dpMetaKeywords
default="default text"
style="lower|upper|title|spaced|roman|decimal|identifier|
noHtml|noHtmlStyle|scriptEncode|uriEncode"
link="on|off"
start="#p|#s|#w|#c|begin|end|resume"
stop="#p|#s|#w|#c|begin|end|resume"
length="#p|#s|#w|#c|begin|end"
>
A T T R I B U T E S:
Notice that style="noHtml" is the default for this tag. This will prevent potential HTML from side effecting meta tags.
Please refer to the common attributes page for the common attribute descriptions.
<dpSection>
D E F I N I T I O N:
The name of the section currently being built or queried. For example, if the story currently being built is within a section named "Music", <dpSection> would return Music.
<dpSection
default="default text"
style="lower|upper|title|spaced|roman|decimal|identifier|
noHtml|noHtmlStyle|scriptEncode|uriEncode"
start="#p|#s|#w|#c|begin|end|resume"
stop="#p|#s|#w|#c|begin|end|resume"
length="#p|#s|#w|#c|begin|end"
>
A T T R I B U T E S:
Please refer to the common attributes page for the common attribute descriptions.
E X A M P L E S:
|
<dpSection> |
Currents |
|
<tt><dpSection style="upper" style="spaced"></tt> |
|
|
<dpIf <dpSection> = "music"> You're in the music section <dpElse> You're NOT in the music section </dpIf> |
You're NOT in the music section |
<dpSectionID>
D E F I N I T I O N:
The section ID of the story currently being built or queried. ID's are always in lowercase and contain no spaces. They are most commonly used to reference image names.
<dpSectionID
default="default text"
style="lower|upper|title|spaced|roman|decimal|identifier|
noHtml|noHtmlStyle|scriptEncode|uriEncode"
link="on|off"
start="#p|#s|#w|#c|begin|end|resume"
stop="#p|#s|#w|#c|begin|end|resume"
length="#p|#s|#w|#c|begin|end"
>
A T T R I B U T E S:
Please refer to the common attributes page for the common attribute descriptions.
E X A M P L E S:
|
<dpSectionID> |
currents |
|
<img src="../images/<dpSectionID>.gif"> |
|
<dpStory>
D E F I N I T I O N:
The story currently being built or queried.
<dpStory
default="default text"
style="lower|upper|title|spaced|roman|decimal|identifier|
noHtml|noHtmlStyle|scriptEncode|uriEncode"
link="on|off"
start="#p|#s|#w|#c|begin|end|resume"
stop="#p|#s|#w|#c|begin|end|resume"
length="#p|#s|#w|#c|begin|end"
images="on|all|off|#|# to #|#,#"
imageStart="#p" (default is 0p)
imageStop="#p" (default is 3/4 way through story)
imageAlign="left|right|toggleLeft|toggleRight|center|none"
imageMacro="macro name"
>
A T T R I B U T E S:
<dpStory images="on">
<dpStory images="1, 3">
<dpStory images="2 to 4">
<dpStory images="2 to 4, 6">
<dpStory images="3 to <dpImageCount>">
right - all images align to the right.
left - all images align to the left
toggleLeft - images toggle left to right, back and forth
toggleRight - images toggle right to left, back and forth
center - centers image and follows it with a <p>
none
Examples:
<dpStory imageStart="2p" imageStop="10p">
This would put the first image after the second paragraph, and the last image after the 10th paragraph. All of the remaining images would be equidistantly dispersed within this range.<dpStory imageStop="14p">
If this story had three images, the first image would be before the first paragraph (default). The middle image would be after the 7th paragraph, and the last image would be after the 14th paragraph. If there was only one image, it would still be before the first paragraph and the imageStop attribute would be ignored.
When defining this layout, you can use any HTML you want and image tags "without" the number attribute. Dispatch will handle advancing the number values for the appropriate images. You may also use other Dispatch tags like conditional statements.
For example:
<dpMacro myImageLayout>Note: Like all macros, this macro needs to be declared before it is used, meaning it must be above whatever references it within your template.
<table border=1 align="<dpImageAlign>" width="<dpImageWidth>">
<tr>
<td>
Image Table<br>
<dpImage><br>
<i><dpImageCaption></i><br>
<font size=2><dpImageArtist></font>
</td>
</tr>
</table>
</dpMacro>
Usage would be as follows:
<dpStory images="all" imageMacro="myImageLayout">
Please refer to the common attributes page for the common attribute descriptions.
<dpSubheadline>
D E F I N I T I O N:
The subheadline of the story currently being built or queried.
<dpSubheadline
default="default text"
style="lower|upper|title|spaced|roman|decimal|identifier|
noHtml|noHtmlStyle|scriptEncode|uriEncode"
link="on|off"
start="#p|#s|#w|#c|begin|end|resume"
stop="#p|#s|#w|#c|begin|end|resume"
length="#p|#s|#w|#c|begin|end"
>
A T T R I B U T E S:
Please refer to the common attributes page for the common attribute descriptions.
E X A M P L E S:
|
<dpSubHeadline> |
Sonoita's Locals Lose An Institution Of Sorts. |
|
<i><dpSubHeadline></i> |
Sonoita's Locals Lose An Institution Of Sorts. |
|
<dpSubHeadline style="lower"> |
sonoita's locals lose an institution of sorts. |
<dpSubheadlineDefault>
D E F I N I T I O N:
This tag will return the subheadline value you have set for this column's default subheadline.
<dpSubheadlineDefault
default="default text"
style="lower|upper|title|spaced|roman|decimal|identifier|
noHtml|noHtmlStyle|scriptEncode|uriEncode"
link="on|off"
start="#p|#s|#w|#c|begin|end|resume"
stop="#p|#s|#w|#c|begin|end|resume"
length="#p|#s|#w|#c|begin|end"
>
A T T R I B U T E S:
Please refer to the common attributes page for the common attribute descriptions.
<dpSummary>
D E F I N I T I O N:
The summary of the story currently being built or queried.
<dpSummary
default="default text"
style="lower|upper|title|spaced|roman|decimal|identifier|
noHtml|noHtmlStyle|scriptEncode|uriEncode"
link="on|off"
start="#p|#s|#w|#c|begin|end|resume"
stop="#p|#s|#w|#c|begin|end|resume"
length="#p|#s|#w|#c|begin|end"
>
A T T R I B U T E S:
Please refer to the common attributes page for the common attribute descriptions.
E X A M P L E S:
|
<dpSummary> |
The Steak-Out, home of the $30 steak with no potato, burned down a week ago last Saturday. |
|
<b><dpHeadline link="on"></b><br> <dpSummary start="begin" length="9w">... |
All Fired Up The Steak-Out, home of the $30 steak with no... |
<dpSummaryDefault>
D E F I N I T I O N:
This tag will return the summary you have set for this column's default summary.
<dpSummaryDefault
default="default text"
style="lower|upper|title|spaced|roman|decimal|identifier|
noHtml|noHtmlStyle|scriptEncode|uriEncode"
link="on|off"
start="#p|#s|#w|#c|begin|end|resume"
stop="#p|#s|#w|#c|begin|end|resume"
length="#p|#s|#w|#c|begin|end"
>
A T T R I B U T E S:
Please refer to the common attributes page for the common attribute descriptions.
<dpUserField>
D E F I N I T I O N:
Returns the value contained in a user defined field (UDF) or the number (count) of values in a user defined field.
<dpUserField
name="(UDFname)"
number="#|all"
return="value|count"
realm="story|column|issue|all"
squeeze="no|yes"
default="default text"
style="lower|upper|title|spaced|roman|decimal|identifier|
noHtml|noHtmlStyle|scriptEncode|uriEncode"
link="on|off"
start="#p|#s|#w|#c|begin|end|resume"
stop="#p|#s|#w|#c|begin|end|resume"
length="#p|#s|#w|#c|begin|end"
>
A T T R I B U T E S:
Please refer to the common attributes page for the common attribute descriptions.
<dpVolumeNumber>
D E F I N I T I O N:
The volume number of the issue currently being built or queried.
<dpVolumeNumber
default="default text"
style="lower|upper|title|spaced|roman|decimal|identifier|
noHtml|noHtmlStyle|scriptEncode|uriEncode"
link="on|off"
start="#p|#s|#w|#c|begin|end|resume"
stop="#p|#s|#w|#c|begin|end|resume"
length="#p|#s|#w|#c|begin|end"
>
A T T R I B U T E S:
Please refer to the common attributes page for the common attribute descriptions.
E X A M P L E S:
|
<dpVolumeNumber> |
15 |
|
<dpVolumeNumber style="roman"> |
XV |
|
Volume <dpVolumeNumber style="roman"> Issue <dpIssueNumber style="roman"> |
Volume XV Issue XVIII |
| Home: Support: Reference Guide: Display Tags | Questions? Comments? Please write support@desert.net. |