XML Collection Function

The XML collection function wraps XML around the parameters of a list of content that’s created as a collection in the Ektron CMS400.NET Workarea. Once created you can use the XML to display the collection information. The ecmCollectionXML function allows you to easily define how the collection data appears on the Web page.

Shown here is the format of the ecmCollectionXML function.

<% ecmCollectionXML

“id”, “GetHtml”

%>

The ecmCollectionXML function attributes are explained below.

Attribute

Description

id

The id of the collection that you would like to be displayed is defined here.

GetHtml

Determines whether the HTML contained within the content is included in the XML output.

0 = Do not get HTML

1 = Get HTML

Note: Ektron recommends using 0 (zero). HTML content can be large and this could cause display problems when your XML collection is displayed on your Web page.

See Also: ”Comparison of Collections, Menus, Taxonomy, and the List Summary Features” on page 1229

When using the XML Collection function, the following tags are created around the properties of each item in the collection.

XML Tags

Description

<Content></Content>

Declares a new section of content in the XML collection.

<ID></ID>

The content block ID.

For example:

<ID>27</ID>

<Title></Title>

The title of the content block.

For example:

<Title>HTML for the World
Wide Web with XHTML and CSS</Title>

<QuickLink></QuickLink>

The quicklink associated with the content block.

For example:

<QuickLink>/CMS400Developer/

collection.aspx?id=27</QuickLink>

<Teaser></Teaser>

The summary of the content block.

For example:

<Teaser>The easiest HTML book weve seen that still manages to be comprehensive.</Teaser>

<Html></Html>

All of the HTML content contained in a content block. See Also: GetHtml

For example:

<Html><em>ASP.NET Unleashed, Second Edition</em> is really big, really thorough, and really <i>good</i>. The explanations are simple and clear as anything weve seen in a .NET book. The sample code addresses virtually every facet of ASP.NET development, from little gems (code for validating credit cards) to full-fledged web stores. Best of all, Stephen Walther identifies the mistakes ASP.NET developers are most likely to make -- and presents detailed solutions. </Html>

<StartDate></StartDate>

The content block’s start date formatted as a .NET date type

For example:

<StartDate>1/1/0001
12:00:00 AM</StartDate>

<DateModified></DateModified>

The last date the content block was modified.

For example:

<DateModified>1/19/2005 4:18:06 PM</DateModified>

<EndDate></EndDate>

The date the content block stops running on the Web site

For example:

<EndDate>12/31/9999
12:00:00 AM</EndDate
>

<LastEditorFname></LastEditorFname>

The first name of the last person who edited the content block.

For example:

<LastEditorFname>John</LastEditorFname>

<LastEditorLname></LastEditorLname>

The last name of the last person who edited the content block.

For example:

<LastEditorLname>Johnson</LastEditorLname>

<Hyperlink></Hyperlink>

The hyperlink shown in the collection for linking to the content block.

For example:

<Hyperlink><a href="/CMS400Developer
/collection.aspx?id=27">

HTML for the World Wide Web with XHTML and CSS</a></Hyperlink>

<DisplayStartDate></DisplayStartDate>

The content block’s start date. It is formatted as a string that represents Ektron CMS400’s display of the date.

<FolderID></FolderID>

The ID of the folder in which the content block is contained.

For example:

<FolderID>0</FolderID>

<ContentStatus></ContentStatus>

The status of the content block.

<Language></Language>

The language of the content block.

<DisplayDateModified></DisplayDateModified>

edited. It is formatted as a string that represents Ektron CMS400’s display of the date.

For example:

<DisplayDateModified>1/19/2005 4:18:06 PM</DisplayDateModified>

<DisplayEndDate></DisplayEndDate>

The content block’s end date. It is formatted as a string that represents Ektron CMS400’s display of the date.

For example:

<DisplayEndDate>12/31/9999 12:00:00 AM</DisplayEndDate>

<EndDateAction></EndDateAction>

What should happen to the content block on its end date.

archive display

archive expire

refresh report

For example:

<EndDateAction>Archive_Expire</EndDateAction>

<Comment></Comment>

Comments contained in the content block.

For example:

<Comment>move picture below text</Comment>

Here is how the raw XML Collection output appears before an XSLT is applied.

<Content>

<ID>24</ID>

<Title>ASP.NET Unleashed</Title>

<QuickLink>/CMS400Developer/collection.aspx?id=24</QuickLink>

<Teaser><p><em>ASP.NET Unleashed, Second Edition</em> is really big, really thorough, and really <i>good</i>.</p></Teaser>

<Html></Html>

<StartDate>1/1/0001 12:00:00 AM</StartDate>

<DateModified>1/12/2005 7:53:31 PM</DateModified>

<EndDate>12/31/9999 12:00:00 AM</EndDate>

<LastEditorFname>Application</LastEditorFname>

<LastEditorLname>Administrator</LastEditorLname>

<Hyperlink><a href=”/CMS400Developer/collection.aspx?id=24”>ASP.NET Unleashed</a></Hyperlink>

<DisplayStartDate></DisplayStartDate>

<FolderID>0</FolderID>

<ContentStatus></ContentStatus>

<Language>0</Language>

<DisplayDateModified>1/12/2005 7:53:31 PM</DisplayDateModified>

<DisplayEndDate></DisplayEndDate>

<EndDateAction>Archive_Expire</EndDateAction>

<Comment></Comment>

</Content>

<Content>

<ID>25</ID>

<Title>Microsoft ASP.NET Programming with Microsoft Visual C#.NET</Title>

<QuickLink>/CMS400Developer/collection.aspx?id=25</QuickLink>

<Teaser><p>Teach yourself how to write high-performance Web applications with ASP.NET and Visual C# .NET--one step at a time.</p></Teaser>

<Html></Html>

<StartDate>1/1/0001 12:00:00 AM</StartDate>

<DateModified>1/4/2005 7:16:21 PM</DateModified>

<EndDate>12/31/9999 12:00:00 AM</EndDate>

<LastEditorFname>Application</LastEditorFname>

<LastEditorLname>Administrator</LastEditorLname>

<Hyperlink><a href=”/CMS400Developer/collection.aspx?id=25”>Microsoft ASP.NET Programming with Microsoft Visual C#.NET</a></Hyperlink>

<DisplayStartDate></DisplayStartDate>

<FolderID>0</FolderID>

<ContentStatus></ContentStatus>

<Language>0</Language>

<DisplayDateModified>1/4/2005 7:16:21 PM</DisplayDateModified>

<DisplayEndDate></DisplayEndDate>

<EndDateAction>Archive_Expire</EndDateAction>

<Comment></Comment>

</Content>

Previous TopicNext Topic|