TextCMS Documentation - Internal Plugins - SUMMARY

Plugin Description

Whole articles can be embedded usilg plugin ARTICLE. But sometimes you just want to embed a link to an article with a preview of its contents. You can use plugin SUMMARY to achieve this. The syntax of the plugin is: [AREA](area_name)[/AREA].

The following parameters in "config.cfg" can be used to control how summary is generated:

<?php

...
TEXTCMS::SetThumbSize ( 180, 135 );
TEXTCMS::SetDefaultThumbImage ( "_media/default.png" );
TEXTCMS::SetSummaryTextLength (200);
...

?>
The first parameter controls the size of a generated thumbnail image. The second parameter specifies an image which is used instead of a thumbnail image when it is not generated (for example when there is no main image defined in an article). The third parameter controls the length of previewed text. Thumbnail image is generated from a main artticle image. You can find out how to specify the main article image in IMAGE plugin documentation (search for attribute "main").

Plugin Usage

This plugin can be used everywhere.

Articles
Templates
Modules
Areas

Attributes

This plugin does not support attributes.

Styling

This plugin generates the following wrapping DIV elements available for styling:

summaryWrapping element for all summary elements
area_(area_name)Wrapping element for individual summary elements

Example

<style>
div.summary
{
	font-size: 64px;
}
div.summary_red
{
	color: #ff0000;
}
div.summary_green
{
	color: #00ff00;
}
</style>

[SUMMARY]red[/SUMMARY]
[SUMMARY]green[/SUMMARY]
(c) 2018-2024 TextCMS