CNCat 3.1 / User manual

© "CN-Software" Ltd. 2002-2007
cncat@cn-software.com
www.cn-software.com

Administration - Settings

Templates

Templates are intended for the user interface settings. HTML-code of a certain page element is defined in a template. For detailed setting (elements order, additional PHP-scripts etc.), one should edit PHP-files of the user interface (see Files structure).


Templates list

A template text may contain parameters of a type "%PARAMETER", which are replaced by the correspponding text; for instance, link name, address etc.


Example of a template

Below there is a list of templates and their parameters.

Note: Parameter %ABS can be used in all templates; it sets absolute path to the script files. It is necessary for correct functioning of search-friendly URLs (this parameter is not indicated in the table).

TemplateDescriptionParameters
"Page" section
top The beginning of a page (1) %TITLE - page title;
%CHARSET - page encoding;
%KEYWORDS - keywords (are used for full description of a link).
catname The catalogue name and its path (3) %MAINTEXT - name of the catalogue;
%OTHERTEXT - path to current category;
%ADMINIFACE - controls for the administrator.
bmenu Menu (2) %MAINTEXT - a text for a link to the catalogue;
%ADDLINKTEXT - a text for a link to a resource addition;
%MODERATORSTEXT - a text for a link to the administrative section.
sortby Sorting (5) %SORTBYTEXT - "Sort by" text
%SORTBYPOP, %SORTBYTITLE, %SORTBYMODER, %SORTBYIN, %SORTBYPR, %SORTBYCY - a text for a sorting by popularity, title, header, vote, date, PR, CY correspondingly.
brokenscript "Broken links" script (JavaScript for the dialog box, displayed after clicking [x] icon) %BROKENSURETEXT - "Are you sure this link is broken?" text
%YESTEXT - Yes
%NOTEXT - No
bottom The end of a page %TITLE - page title
%COPYRIGHT - CNCat Copyright.
"Links list" section (6, 7)
linkstop Part of HTML page before the links list -
bestlinksbit The best link %ID - link identifier
%TITLE - site name
%GIN - number of jumps from the site to the catalogue
%GOUT - number of jumps from the catalogue to the site
%MODERVOTE - the administrator's grade
%RATINGPR - Google PR
%RATINGCY - Yandex CY
%BEST - a star icon for best links (displayed for the administrator's vote = 10)
%DESC - description
%FULLDESC - full description
%KEYWORDS - keywords
%RESFIELD1 - additional field 1
%RESFIELD2 - additional field 2
%RESFIELD3 - additional field 3
%EXTINFOLINK - is replaced by extinfolink template, in case links to the detailed resource description are enabled
%EXTENDEDINFOURL - a link to the detailed resource description
%URL - site URL
%BROKENTEXT - "x" letter in the icon [x]
%ADMINIFACE - link controls for the administrator
linksmiddle Part of HTML page between the best and regular links %NUM - o Secuence number of the first link (depends on a current page number).
linksbit Link See bestlinksbit
linksbottom Part of HTML page after the links list -
extinfolink Link to the detailed resource description %EXTENDEDINFOURL - Link to the detailed resource description
"New links" section
newlinkstop Upper part of "New Links" section %NEWLINKSTEXT - title of the section
newlinkstbit A new link %ABS
%ID - link identifier
%EXTENDEDINFOURL - link to the detailed resource description
%TITLE - site name
%GIN - number of jumps from the site to the catalogue
%GOUT - number of jumps from the catalogue to the site
%MODERVOTE - the administrator's grade
%DESC75 - brief description
%DESC - description
%URL - site URL
%RESFIELD1 - additional field 1
%RESFIELD2 - additional field 2
%RESFIELD3 - additional field 3
newlinkstbottom Lower part of "New Links" section -
"List of categories" section (4)
partstop Upper part of "Categories" section -
partsdelimtop The beginning of a new line of the categories section %WIDTH - column width of the categories table
partsbit Name of a category %CTITLE - category name
%URL - category URL
%CCOUNT - number of links in a category
%SUBPARTS - is replaced by subcategories list (see subparts... templates)
subpartstop The beginning of subcategories section -
subpartsbit Subcategory template %URL - subcategory URL
%CTITLE - subcategory title
subpartsdelim subcategories delimiter -
subpartsmore '...' at the end of the categories list if it continues -
subpartsbottom The end of subcategory section -
partsdelimbottom The end of a new line of the categories section -
partsbottom Lower part of the categories section -
"Search"
searchform Search form (3) %QUERYTEXT - search request
%SEARCHTEXT - "Search" button text
searchtop Part of HTML page before the links list %STARTNUM - sequence number of the first link on the page.
hltop The beginning of the search result highlighting -
hlbottom The end of the search result highlighting -
searchbottom Part of HTML page after the links list -

Back | Manual index | Next