charttemplate

Date: 13-04-2007 13:17 Views: 2909 Author: Colin Polonowski

Description:

Provides simple chart functionality based on a specific content type. It shows the top n items of content based on views over a period specified in the 'Site Settings' screen. It uses templates to display the content in the preferred format.

There are six parameters:

1. definition id - the id of the content you'd like to display in the chart. Note: From version 0.8.0 this can be a comma separated list of Definition IDs to allow the chart to contain more than one type of content. If a Definition ID of 0 is supplied, all content is included.
2. number of items - the number of pieces of content to display in the chart
3. standard template - the fixed template that determines the layout of each entry
4. first template (optional) - if a different templated is to be used for the item that is at the top of the chart it should be specified here
5. header template (optional) - if specified, the template that is placed at the beginning of the chart
6. footer template (optional) - if specified, the template that is placed at the end of the chart
7. since when - if specified, will display only a chart of content posted after a specified date. Options available are last_year, last_month, last_week, yesterday

Syntax:

(charttemplate|definition id|number of items|standard template|first template|header template|footer template|since when)

Examples:

  • (charttemplate|1|10|ChartStandardTemplate|ChartFirstTemplate|ChartHeaderTemplate|ChartFooterTemplate)
    Displays a chart of content with the definition id of 1. It'll show the top 10 pieces of content and will use the ChartStandardTemplate, ChartFirstTemplate, CharHeaderTemplate, ChartFooterTemplate templates to display the chart as the user requires

  • (charttemplate|1,2,3|10|ChartStandardTemplate|ChartFirstTemplate|ChartHeaderTemplate|ChartFooterTemplate)
    Displays a chart of content with the definition ids of 1, 2 or 3. It'll show the top 10 pieces of content and will use the ChartStandardTemplate, ChartFirstTemplate, CharHeaderTemplate, ChartFooterTemplate templates to display the chart as the user requires

  • (charttemplate|0|10|ChartStandardTemplate|ChartFirstTemplate|ChartHeaderTemplate|ChartFooterTemplate)
    Displays a chart of all content. It'll show the top 10 pieces of content and will use the ChartStandardTemplate, ChartFirstTemplate, CharHeaderTemplate, ChartFooterTemplate templates to display the chart as the user requires