Style template tags

Style Templates are HTML pages or page fragments, sprinkled with ViewsFlash-specific substitution tags. These tags tell ViewsFlash, for example, where to insert the results of a poll, such as how many people have voted.

For example, suppose that you have created a poll in which the question "Party" is asked, with two possible answers, "Democrat", and "Republican". If your Response Style template contained the following HTML:

Party affiliation: [/Party,pollcount] people responded
[/Party,count,Democrat] Democrats ( [/Party,pct,Democrat] %)
[/Party,count,Republican] Republicans ( [/Party,pct,Republican] %)

when the Poll response page is displayed, it would look like:

Party affiliation:1370 people responded
587 Democrats ( 43 %)
783 Republicans ( 57 %)

From this example, you can see that the substitution tags have been replaced with various values from the polls, such as the number of people who responded (pollcount), how many people (count) voted Democrat and Republican, and the percentage (pct) of people who voted Democrat and Republican.

A tag has the form [/tag,tag,tag,tag]  Note the [/ and the ending ]

Inside the [/ and ], a tag has several parts, which are keywords separated by commas; their meaning varies as described below.

The tags can be inserted anywhere on a page; they are only meaningful to ViewsFlash. If you use a web page editor, it will show the tags as text. If you prefer, there is an alternate syntax for ViewsFlash tags.

Instead of [/tag,tag,tag,tag] you can use <vwf=tag,tag,tag,tag>

Style Templates can be edited from ViewsFlash, using the Style Templates pages. You can also edit the templates in your favorite web page editor, upload them to the ViewsFlash server site, and then edit them using the Style Templates pages.

Some editors will hide the alternate syntax; some editors will highlight it. Which one you use is up to you. They are completely interchangeable. It is often desirable to put a ViewsFlash tag in between table rows (<tr></tr>) tags. Some editors will not allow the [/...] form and it is necessary to use the <vwf=...> form. If you will be using an editor to edit the Style Templates, experiment with it to see which tags work. But it may be considerably easier to just edit the HTML in the Style Template pages.

Style tags often come in pairs, such as [/allquestions] [/endallquestions], or <vwf=allquestions> <vwf=endallquestions>. In such cases, all HTML between the tags will be treated as a unit, whose meaning depends on the tag.

Different style tags are available for poll pages, response pages, and archive pages. Additional, special tags are available for quizzes.

Next: Form style tags