Overview of All Link Page Template Variables
LinkAssistant offers more than 50 link page template variables (some with individual parameters) so that you can create fully customizable links pages or directories. These variables control exactly what information gets into your links page. LinkAssistant substitutes the variables with the appropriate values from the current project properties - so you won't see them in your generated HTML pages - they are used in templates only.
These variables are much about the same as usual HTML tags (that is why they are sometimes called "meta-tags"), but differ from HTML tags in the enclosing brackets - LinkAssistant's variables use "<[ ]>" brackets instead of usual "< >". Just as HTML tags, there are opening meta-tags (<[ ]>) and closing ones (<[/ ]>). Besides, they are highlighted in red in the template editor.
Service Meta-Tags Are Highlighted In Red
Below you can find short description for any tag with examples showing: 1) a template fragment with one particular tag; 2) HTML code to be generated by this tag; 3) a screenshot of a real page generated with the help of this template snatch.
Let's start...
Variables That Can Be Used Only Once:
One of these variables must always be at the beginning (opening meta-tag) and at the end (closing meta-tag) of any template. ANY other variable must be within.
<[LINKS_LIST_VIEW]> ... <[/LINKS_LIST_VIEW]> - allows to create so-called "plain" links pages (i.e. a set of pages which do not use "links from one category are located on a separate page" approach).
or
<[DIRECTORY_VIEW]> ... <[/DIRECTORY_VIEW]> - creates a more sophisticated, multi-level links directory. By default one page is generated for each category. But you can certainly change this behavior by changing, for example, the perPage parameter of this tag.
Possible parameters:
hideEmpty - specifies whether empty categories should be included into the generated HTML code or not. Possible values are "true" or "false" ("false" is used by default).
perPage - splits pages with a big number of partners to some smaller pages. Parameter specifies a maximum number of link partners to be located per one page.
pageNaming - sets the pages' naming rule, i.e. how should be generated pages named. Possible values are:
- "dash-delimited" (in this case files will be named like "root-cat1-3.html"),
- "underscore-delimited" ("root_cat1_3.html"),
- "continuous" ("rootcat13.html"),
- "numeric" (e.g. 132-3, where 132 is some unmeaning number generated by LinkAssistant, and 3 is a page number in this category).
The default value is "dash-delimited".
Example:
<[DIRECTORY_VIEW hideEmpty="true" pageNaming="underscore-delimited"]> ... <[/DIRECTORY_VIEW]> |
This example outputs the HTML code with no empty categories (i.e. categories with no link partners) in it, and pages will be named smth like "root_cat1", "root_cat2", "root_cat3", etc. Since there is no perPage parameter, all links of one category will be located on one page (i.e. pages will not be splitted by, say, twenty links per page).
Loop Variables:
These variables usually enclose other links variables as well as any HTML text.
<[FOR_EACH_CATEGORY]> ... <[/FOR_EACH_CATEGORY]> - for each category of the current project it will place into the HTML code everything, which is located between the opening and the closing tags.
Possible parameters:
hideEmpty - specifies whether empty sub-categories (i.e. sub-categories with no link partners) of this category should be included into the generated HTML code or not. Possible values are "true" or "false" ("false" is used by default).
Example:
<[FOR_EACH_CATEGORY]> <[CATEGORY_NUMBER/]>) <[CATEGORY_NAME/]>. <br> <[/FOR_EACH_CATEGORY]> |
outputs the enumerated list of all category names from the current project (including empty categories) with the dot at the end of each category name, like:
|
1) Cat1. 2) Cat2. ... |
<[FOR_EACH_SUBCATEGORY]> ... <[/FOR_EACH_SUBCATEGORY]> - for each sub-category of the current category it outputs into the HTML code everything which is located between the opening and the closing tags.
Possible parameters:
hideEmpty - specifies whether empty sub-categories (i.e. sub-categories with no link partners) of this category should be included into the generated HTML code or not. Possible values are "true" or "false" ("false" is used by default).
Example:
<[DIRECTORY_VIEW]> ... <[FOR_EACH_SUBCATEGORY hideEmpty="true"]> <b> <a href="<[CATEGORY_PAGE_FILE/]>"><[CATEGORY_NAME/]></a> </b><br> <[/FOR_EACH_SUBCATEGORY]> ... <[/DIRECTORY_VIEW]> |
will output all the names of sub-categories of the first level with hyperlinks to the pages of these sub-categories:
|
Cat1
Cat2 ... |
<[FOR_EACH_CATEGORY_IN_PATH]> ... <[/FOR_EACH_CATEGORY_IN_PATH]> - it outputs everything which is located between the opening and the closing meta-tags for all categories that form the path from the root category to the current one.
Example:
<[FOR_EACH_CATEGORY_IN_PATH]> <a href="<[CATEGORY_PAGE_FILE/]>"><[CATEGORY_NAME/]></a> >  <[/FOR_EACH_CATEGORY_IN_PATH]> <b><[CATEGORY_NAME/]></b> |
will output all the names of all categories starting from the root category to the current one:
| Root > Cat1 > Cat2 |
<[FOR_EACH_PARTNER]> ... <[/FOR_EACH_PARTNER]> - outputs everything which is located between the opening and the closing meta-tags for every partner from the current category/sub-category/...
Possible parameters:
sortBy - specifies the sorting order. Possible values are:
- "domain" (in this case all partners will be processed in alphabetical order by their domains),
- "description" (partners will be processed in alphabetical order by their descriptions),
- "entranceDate" (partners will be ordered by the date when they were included in your project),
- "name" (obviously, partners will be processed in alphabetical order by their names. Besides, the "name" parameter is used by default).
Example:
<ul> <[FOR_EACH_PARTNER]> <li> <[PARTNER_NUMBER/]>. <a href="<[PARTNER_DOMAIN/]>"><[PARTNER_NAME/]></a> <br> <[PARTNER_DESCRIPTION/]> </li> <[/FOR_EACH_PARTNER]> </ul> |
will output an enumerated list of partner names and descriptions with hyperlinks to their wesites:
|
1. LinkAssistant SEO Tool
Promote Your Website Easily with LinkAssistant - Powerful SEO Software for Reciprocal Link Exchange 2. ... |
<[FOR_EACH_PAGE]> ... <[/FOR_EACH_PAGE]> - outputs everything which is located between the opening and the closing meta-tags for every generated page.
Example:
<[FOR_EACH_PAGE]> <a href="<[PAGE_FILE/]>"><[PAGE_NUM/]></a> <[IF_HAS_NEXT_PAGE]> <[THEN]> : <[/THEN]> <[/IF_HAS_NEXT_PAGE]> <[/FOR_EACH_PAGE]> |
will output a colon-delimetered list of page numbers, each linking to the corresponding web page:
| 1 : 2 : 3 |
Flow Control Variables:
<[IF_IS_FIRST_PAGE]> ... <[/IF_IS_FIRST_PAGE]> - this variable will place into the HTML code everything which is located between the opening and the closing tags on the first page ONLY. The "first" page is a page where all top-level categories are located (for the "directory" view), or just the first links page (for the "plain" view) (if you choose not to split this page by limiting maximum number of links per page - then this one page will also be the first).
Example:
<[IF_IS_FIRST_PAGE]> <[THEN]> Welcome to the Home Page of our Links Directory! <[/THEN]> <[ELSE]> This is Not the Home Page of the Links Directory. <[/ELSE]> <[/IF_IS_FIRST_PAGE]> |
displays the
| "Welcome to the Home Page of our Links Directory!" |
| "This is Not the Home Page of the Links Directory." |
<[IF_HAS_PREVIOUS_PAGE]> ... <[/IF_HAS_PREVIOUS_PAGE]>
<[IF_HAS_NEXT_PAGE]> ... <[/IF_HAS_NEXT_PAGE]>
<[IF_IS_CURRENT_PAGE]> ... <[/IF_IS_CURRENT_PAGE]>
These tags are useful in case of splitting pages by limiting maximum number of links per one page. They display all information that is written between the inner <[THEN]> ... <[/THEN]> tags if the page is
1) not the first page among these "splitted" pages;
2) not the last one;
3) this is the page being currently processed.
Please take a look at the example below to make the things clear:
Example:
<[FOR_EACH_PAGE]> <[IF_IS_CURRENT_PAGE]> <[THEN]> <b><[PAGE_NUM/]></b> <[/THEN]> <[ELSE]> <a href="<[PAGE_FILE/]>" class="link"><[PAGE_NUM/]></a> <[/ELSE]> <[/IF_IS_CURRENT_PAGE]> <[IF_HAS_NEXT_PAGE]> <[THEN]> : <[/THEN]> <[/IF_HAS_NEXT_PAGE]> <[/FOR_EACH_PAGE]> |
This template's snippet will be transformed into a set of page numbers linking to the corresponding pages delimitered by colon. Please note the the current page doesn't link to itself, but is written in bold instead:
| 1 : 2 : 3 |
Note:
Please pay attention to the inner <[THEN]> ... <[/THEN]> and <[ELSE]> ... <[/ELSE]> tags. These tags must be used within <[IF_...]> tags only and allow to output the text inside them only if the IF-clause is thrue or false respectively.
Link Partners Variables:
These variables are not separated into closing and opening parts - they consist of one tag which has a slash symbol before the closing brackets <[ /]>.
Link Partners variables allow to display your link partners' properties (such as thier names, domains etc) on the resulting HTML pages. As a rule, they are used inside the <[FOR_EACH_PARTNER]> ... <[/FOR_EACH_PARTNER]> tag.
Let's take a closer look at them...
<[PARTNER_DOMAIN/]> - outputs your partner's domain (for example, http://www.link-assistant.com).
<[PARTNER_NAME/]> - displays your partner's name (for example, LinkAssistant SEO Tool).
<[PARTNER_DESCRIPTION/]> - displays your partner's description (for example, Promote Your Website Easily with LinkAssistant - Powerful SEO Software for Reciprocal Link Exchange).
<[PARTNER_EMAIL/]> - outputs your partner's email address (for example, links@some-domain.com).
<[PARTNER_LINK_PAGE/]> - represents an URL of a concrete page where a reciprocal link to your site is located (for example, http://www.some-site.com/links.html).
<[PARTNER_INCLUSION_DATE format="dd:MM:yyyy HH:mm"]> - outputs a date when you included this link partner into your project (for example, 21:09:2005 17:43).
<[PARTNER_BANNER/]> - represents a banner URL in case of using banner ads (for example, http://www.link-assistant.com/banner.jpg).
<[PARTNER_GOOGLE_PR_POPULARITY/]> - displays partner website's Google PageRank (Google PR is always an integer between 1 and 10).
<[PARTNER_GOOGLE_POPULARITY/]> - displays partner website's Google link popularity (go read more about link popularity at our glossary).
<[PARTNER_YAHOO_POPULARITY/]> - displays partner website's Yahoo link popularity.
<[PARTNER_MSN_POPULARITY/]> - displays partner website's MSN link popularity.
<[PARTNER_NUMBER/]> - allows to enumerate links of the current category or project.
<[AMOUNT_OF_PARTNERS_IN_CATEGORY/]> - displays the number of links of the current category.
<[AMOUNT_OF_PARTNERS_IN_PROJECT/]> - displays the number of links of the project.
Example:
Suppose you have exchanged links with Link-Assistant.Com and now one of your partners looks like:
Link Partner Properties
In this case
<ul> <[FOR_EACH_PARTNER]> <li> <a href="<[PARTNER_DOMAIN/]>"><[PARTNER_NAME/]></a> <br> <[PARTNER_DESCRIPTION/]> <br><b>Contact:</b> <[PARTNER_CONTACT_NAME/]> (<a href="mailto:<[PARTNER_EMAIL/]>"><[PARTNER_EMAIL/]></a>) </li> <[/FOR_EACH_PARTNER]> </ul> |
will output the following information:
|
Category Variables:
Just as Link Partners Variables, these variables are not separated into closing and opening parts - they consist of one tag which has a slash symbol before the closing brackets <[ /]>.
Category variables allow to manage categories' properties (such as categories' names, numbers, pages etc). As a rule, they are used inside the
<[FOR_EACH_CATEGORY]> ... <[/FOR_EACH_CATEGORY]>,
<[FOR_EACH_SUBCATEGORY]> ... <[/FOR_EACH_SUBCATEGORY]> or
<[FOR_EACH_CATEGORY_IN_PATH]> ... <[/FOR_EACH_CATEGORY_IN_PATH]> tags.
Let's take a closer look at category variables...
<[CATEGORY_NAME/]> - outputs the current category name (for example, Link Exchange).
<[CATEGORY_PAGE_FILE/]> - represents the file name of the current category (for example, resources-link-exchange.html).
<[CATEGORY_NUMBER/]> - used for enumerating categories. Displays category number.
<[AMOUNT_OF_CATEGORIES/]> - displays the number of categories of the project.
<[AMOUNT_OF_SUBCATEGORIES/]> - displays the number of sub categories of the current category.
Example:
Suppose you have the following categories in your project:
Categories
In this case
<[DIRECTORY_VIEW]> <html> <body> <p><b><[CATEGORY_NAME/]></b></p> <!-- List of child categories - Start --> <[FOR_EACH_SUBCATEGORY hideEmpty="false"]> <p><b> <a href="<[CATEGORY_PAGE_FILE/]>"><[CATEGORY_NAME/]></a> (<[AMOUNT_OF_SUBCATEGORIES/]>) </p></b> <[/FOR_EACH_SUBCATEGORY]> <br> <!-- List of child categories - End --> </body> </html> <[/DIRECTORY_VIEW]> |
will generate the following home directory page:
|
Resources |
Project Variables:
Just as Link Partners Variables and Category Variables, these variables are not separated into closing and opening parts - they consist of one tag which has a slash symbol before the closing brackets <[ /]>.
Project variables allow to display you project properties (such as your website's domain, name, your email etc), which you can enter in the "Edit Project Properties" dialog (see the Creating a New Project section of this Tutorial).
<[YOUR_SITE_DOMAIN/]> - outputs your website's domain (for example, http://www.link-assistant.com).
<[PARTNER_NAME/]> - displays your website's name (for example, LinkAssistant SEO Tool).
<[PARTNER_DESCRIPTION/]> - displays your website's description (for example, Promote Your Website Easily with LinkAssistant - Powerful SEO Software for Reciprocal Link Exchange).
<[PARTNER_EMAIL/]> - outputs your email address (for example, links@some-domain.com).
<[YOUR_CONTACT_NAME/]> - outputs your contact name (for example, John Doe).
<[YOUR_GOOGLE_PR_POPULARITY/]> - displays your website's Google PageRank (Google PR is always an integer between 1 and 10).
<[YOUR_GOOGLE_POPULARITY/]> - displays your website's Google link popularity.
<[YOUR_YAHOO_POPULARITY/]> - displays your website's Yahoo link popularity.
<[YOUR_MSN_POPULARITY/]> - displays your website's MSN link popularity.
Example:
For the Link-Assistant.Com website we have the following properties:
Link-Assistant.Com Project Properties
In this case this template snippet
<p><[YOUR_SITE_NAME/]> - <[YOUR_SITE_DOMAIN/]></p> <p><[YOUR_SITE_DESCRIPTION/]></p> <p>Contact: <[YOUR_EMAIL/]> (<[YOUR_CONTACT_NAME/]>)</p> |
will output the following:
|
LinkAssistant SEO Tool - http://www.link-assistant.com Promote Your Website Easily with LinkAssistant - Powerful SEO Software for Reciprocal Link Exchange Contact: links@some-domain.com (John Doe) |


