More Scripts Flash Calendar Hover POP RSS to HTML
Flash poll
Home
Demo
Features
Installation
Buy
Contact
Flash Poll > Installation

Web Poll™ is the easiest way to create dynamic online web polls

After buying the poll please follow the steps below to have the demo poll installed on your web site.

1) as you can see there are 4 files in the zip file
  • default.xml - this is the demo configuration file. Poll question, answers and colors are saved in this file. You can edit it using a plain text editor such as notepad.
  • pollxml.swf - this is the actual flash engine
  • php file - this is a PHP script used by the flash engine to update the configuration file.
  • example.html - this is a demo web page with simple HTML code to show the poll

2) upload the first 4 of the above files in a folder on your web server

3) depending on your server configuration you may need to change the permissions to your configuration file (default.xml) to 777 so it is writable by the php script.

4) all you have to do now is to open the demo web page at at http://www.yoursite.com/folder/example.html (where yoursite.com is the domain name and 'folder' is the folder where you uploaded the files.

Changing the Demo poll and creating your own one

To change Poll question, answers and colors you should edit default.xml file or create new XML file. Bellow you can see the contents of the demo XML file (default.xml). All colors use HTML color codes. If you are used to use #FFFFFF code all you have to do is change it to 0xFFFFFF (FFFFFF is the HTML color code for white).

<poll id="0011" backTitle="0x9C181A" colorTitle="0xFFFFFF" colorBackground="0x797806" colorAnswers="0xFFFFFF" btnColor="0x9C181A" btnTitle="0xFFFFFF" totalColor="0xDDDDDD" colorBar="0x9C181A" days="0" results="amount_percent" onvote="total">
<question>Is web poll the product that you've been looking for?</question>
<answers>
<answer id="0" votes="501">YES it's perfect</answer>
<answer id="1" votes="231">ALMOST what I am looking for</answer>
<answer id="2" votes="101">Hmm, not quite sure yet</answer>
<answer id="3" votes="54">NO, it is not for me</answer>
</answers>
<message>Thank you</message>
<voteMsg>Vote me</voteMsg>
<totalMsg>Total:</totalMsg>
</poll>

  • id="0111" - this is an unique poll ID. It can be anything - letters, digits, letters and digits. It is used to identify your web site visitors if they've voted or not on each of the polls that you have.
  • backTitle="0xAAAA0B" - background color for the question box
  • colorTitle="0xFFFFFF" - text color for the question
  • colorBackground="0x797806" - background color for the poll
  • colorAnswers="0xFFFFFF" - text color for all the answers
  • btnColor="0x9C181A" - VOTE button background color
  • btnTitle="0xFFFFFF" - VOTE button text color
  • colorBar="0x9C181A" - color for vote results bars below each answer
  • totalColor="0xDDDDDD" - color for the total votes message
  • days="0" - you can set the amount of days that people should wait before being able to vote again. If you leave this 0 then people will be able to vote as many times as they want
  • results="amount_percent" - it can be: amount, percent, amount_percent, nothing. amount - shows number of votes for each result, percent - show percent of votes for each answers , amount_percent - shows both number and percent for each answer, nothing - do not show amount of votes.
  • onvote="total" - it can be: total, nothing, message. total - shows the total number of votes, nothing - shows nothing, message - shows custom message defined in the <message> tag below.
  • <question>Is web poll the product that you've been looking for?</question> - make sure that you put the question between the <question> and </question> tags
  • <answer id="0" votes="4230">YES it's perfect</answer> - make sure that you put the answers between <answer> and </answer> tags
    - id="0" - this is unique ID for each answer. IDs should be consecutive starting from 0
    - votes="4230" - this is the number of votes for each answer. This is the value that is updated by the PHP script when somebody votes on your poll
  • <message>Thank you</message> - you can define a custom message to show up when someone votes.

    Bellow you can see the HTML code used to display the demo poll.

    <object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/ shockwave/cabs/flash/swflash.cab#version=7,0,0,0" width="160" height="320" align="middle">
    <param name="allowScriptAccess" value="sameDomain" />
    <param name="movie" value="pollxml.swf?datafile=default.xml&owner=vevs.com" />
    <param name="quality" value="high" />
    <param name="bgcolor" value="#ffffff" />
    <embed src="pollxml.swf?datafile=default.xml&owner=vevs.com" quality="high" bgcolor="#ffffff" width="160" height="320" align="middle" allowscriptaccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />
    </object>

    The two importand parts in the code are in bold.

  • pollxml.swf?datafile=default.xml&owner=vevs.com - you can specify the XML configuration file. If you create a new XML configuration file with a new name you should change the datafile=default.xml to datafile=newfilename.xml. The owner=vevs.com is there so we can be sure that you will not resell the script. If you decide to resell the script without our permission your "clients" will see this in the HTML code and will find our web site - the real owners of the poll script. The poll does not connect to or rely on our servers.
  • Web Poll dynamically calculates the size needed for the question and answers boxes. For example, when you create a poll and enter a five 100 characters long answers the poll calculates that it will need 2 lines for each answer and will set its height to be enought for all the answers. However, you should manually adjust poll height in the HTML code (height="320" means that HTML page will display 320 pixels height poll). When doing a poll we would suggest that you first set a higher value (height="600") and if all answers and vote button fits in you can lower the poll height.
  • You can also change poll width by editing width="160"
Copyright Web Poll™ by Vevs.com© 2003
Home | Demo | Features | Installation | Buy | Contact