The Production Cycle


After the ViewsFlash software is installed, here's what you will need to do to produce questionnaires.

Standard uestionnaires with default settings are dynamically composed by ViewsFlash, and are simply referred to by their URL, which is shown in a very visible box at the bottom of the the Publish page.

All you need to do is to use the URL in the Publish page to direct visitors to the questionnaire:

If you use Invitation lists, emails use this this URL.

Standard questionnaires can easily be embedded in a JSP page.

In Portals, there is no production cycle. See the User Guide for your portal at under JSR 168 portlet.

An embedded poll is one where the voting form and the results display are embedded inside a containing web page, thus requiring additional setup. If the site is using a content management system, each page containing a place is modified to include the appropriate publishing system tags in the spot reserved for the place. These tags ask ViewsFlash for the HTML fragments to use.

If you don't need to embed polls, skip the rest of this section.

In addition to using a JSP page (the easiest method) or an IFrame, two methods for embedding polls and results into a web site are described here. IFrames are found in the Support section of

If the site uses a Content Management System for dynamically constructing web pages, the ViewsFlash Web Services API provides the appropriate HTML fragments as needed. If a site does not use a Content Management System and uses static HTML, ViewsFlash can write fragments or even modify the pages where polls are embedded if necessary. Here are additional considerations.

Feature Content Management System Shared Files
ViewsFlash provides Poll voting form HTML fragments via an HTTP request by writing them to shared file system
Containing pages must have tag to invoke WPS <vwf=embed> and <vwf=endembed> tags
File systems on two servers completely separate must be shared
Display poll or results, depending on prior voting easy requires two complete pages
Results can be live yes yes
Results can be cached yes no
Settings to use in place Setup Use "a complete web page" Use "An HTML fragment"
See also Web Services API  

Producing whole-page polls and surveys

1. The Designer should create a set of Style Templates to give the questionnaires the look and feel of your site. Start by copying the Standard_ template, and embellish it as appropriate, adding headers, banners, etc.. Similarly, use a copy of the Results template as a starting point for your own Response Template. Likewise, start with the MenuArchive or the ListArchive templates and add to them accordingly.

Once these templates are created, you'll be able to reuse them over and over at many places.

2. The Editor, for each poll or survey, creates a place and chooses the appropriate templates. Settings should specify "whole page." After going through the normal design process, the URL is found in the Publish screen. The Designer uses that URL to link to the poll page or to publicize the survey by e-mail to bring people to the polling page. The page can also be e-mailed directly to people using HTML-capable e-mail software.

Producing embedded polls by hand

This is by far the easiest way to create embedded polls. The Editor creates a place, using an embedded style template, and publishes a poll. The Designer goes to the Publish page, clicks on the link below the Submit button with the Poll URL, and copies the entire contents of the window that pops up to the proper spot in the page where the poll should appear. If the template included JavaScript for showing the results in a pop-up window, you're done.

Producing embedded polls and surveys with a content management system.

See the Automated Poll Rotation.

Producing embedded polls and surveys without a content management system.

In the absence of a content management system, ViewsFlash writes HTML fragments on the file system. There are two ways to embed them in the containing pages: server-side includes and modifying the containing pages. Both methods require that the main web server and the ViewsFlash web server either be the same web server, or that they share a common file system.

1. The Administrator configures the web servers so that they have a shared file system. In the Administration screen, the URL and the location of the main web server's document root are provided, as seen from the ViewsFlash machine.

2. The Designer develops a set Style Templates, using with the HTML Fragment Poll and Result templates and the List and Menu Archive templates. All templates should omit <head> and <body> tags, as they will be used to generate HTML that will be dropped into the middle of a web page by the publishing systems. These templates can be reused over and over.

3. The Editor, for each poll or survey, creates a place and chooses the appropriate templates. The Settings to use depend on whether server side includes are being used or not.

In Step 2, choose "An HTML fragment", and enter the name of the page on the main web server, such as "News/Domestic.html", or "Politics.html". Choose the appropriate radio button depending on whether you are using server-side includes or not.

In Step 4, choose "An HTML fragment". ViewsFlash will use the settings in Step 2 to retrieve a copy of the containing page, embed the results between the <vwf=embed> and <vwf=endembed> tags, and display the resulting page in response after recording the visitor's vote.

The Designer includes the following HTML in the place on the containing web page where the poll will appear:


If using server-side includes to incorporate the HTML fragment into the containing page, it appears in between these tags:

<--#include virtual="/viewsflashserver/htdocs/pollhtml/pollingplace.html" -->

Note that in the server-side include, the HTML fragments are being included from a directory that the ViewsFlash web server writes to. If you are not using server-side includes, then the ViewsFlash server will modify the containing web page whenever the scheduled poll changes, but not in between.

After this, the Editor can design additional polls in the same web page, without modifying either the containing web page or the Style templates.

If you plan on using a Content Management System, read about the Web Services API. Otherwise, you can also skip right to Style Templates.

Next: How to use the Web Services API