To start a poll you have to create a new poll record. To do so, choose a site which contains the records an use the click-menu to create a new one.
A form opens, showing a poll record:
There are fields where you can put a title, an image and your question. The important part is the textbox for your answers.
Every line describes an answer. The amount of votes for an answer are shown in the textbox “Votes”. When you set up the poll this box should be clear or have a value of “0“ for every answer. To define in which color the answer should be rendered you can use the field “Color”. As colors you can use by default blue, red, yellow, green and black. Other colors can also specified (see section Configuration). If you don't define a color the default one is taken from the plugin configuration.
Here is an example for a poll wit some colors defined:
Answers:yesno
don't know
Colors:
green
blue
yellow
To allow votes only until a special day but to show the result of the poll after this day you can use the field “valid till” at the very beginning of the form. Votes are only possible until the day specified.
You now have to insert a plugin as pagecontent to the page the poll should be displayed on in the frontend. To do so, create a new pagecontent and select “Insert plugin” as type. In the drop-down box “Plugin” you have to select “Poll”. After this you can see a form like this:
If the page where you created the poll record isn't the same as the one where you inserted the plugin, you have to define the page with your poll record in the field “Startingpoint. If it is the same page, nothing special has to be done. Save the form and view the page on which you inserted the pagecontent (use the button “Save document and view page” on top of the form). You should now see your poll.
There are several options to configure your poll. They are separated in “General Settings” and “Template”.
General Settings:
Option | Description |
|---|---|
What to display | You can select the values “POLL” or / and “LIST”. With “POLL” you display the newest poll. “LIST” shows a list of all polls located at the specified Startingpoint. |
Amount of polls (LIST) | Limit the amount of shown polls to the inserted value. Only takes effect if “LIST” is selected in first option. |
Show first poll in LIST | Specifies if the newest poll should be shown in LIST or not. Only takes effect if “LIST” is selected in first option. |
Allow votes for old polls in LIST | When selected it is possible to vote for an old poll located in the list. Only takes effect if “LIST” is selected in first option. |
Set cookie for x days (value "off" for non-persistent cookie) | Specifies for how many days the cookie, preventing a visitor from voting again, will last. If you use the value "off" non-persistent cookies will be used (the cookies are deleted when the session ends). If no value is entered the default is 30 days. To disable cookies completely it is also possible to insert “no”. |
Allow only fe_users to vote | Only Frontend users can vote for an answer (you could set the cookie value to “no” to disable cookies). |
Check IP before vote is possible | When selected the IP-addresses of the visitors who voted for an poll are saved. This can be used to prevent visitors to vote more than once when they disabled cookies. |
Allow another vote after x hours | Allows another vote from an IP logged as already voted after specified value of hours. To specify values different from full hours use numbers like 0.5 for half an hour (you have to use a dot, commas are not accepted. Only takes effect if “Check IP before vote is possible” is selected in the option before. |
Use captcha (Extension Captcha is required) | To vote for an answer the user has to insert a special string (see extension Captcha from Kasper). |
Template:
Option | Description |
|---|---|
Page for single view (POLL) | If you only selected the value “LIST” in the section “General Settings” you have to specify a page where a plugin with “POLL” exists, because the results of the polls will be displayed there. (Normally you should use the value “LIST” in connection with “POLL”) |
Type | Specifies the type of the poll. It can be chosen between horizontal and vertical ((see screenshots in section Introduction). |
Template | You can set a template-file which should be used in the rendering process of the poll, if you'd like to adopt the layout to your needs (see Configuration). |
Color | The default color if no color is defined in the poll record. The same values as in the poll record can be used here. If no color is given the default is blue. |
Path for images | Specify path where images can be found (e.g.: /fileadmin/template/images/). Default value is EXT:jk_poll/images/ |
Height/Width | The height or the width of the poll bar (depends on the type of the poll selected before). You should try some values to find one which suits you best. |
Factor | The factor is used to stretch the poll bars. The size of the poll bars is the percentage of votes in pixel. Due to this fact they could be rather small, the factor is multiplied with the amount of pixels. A suitable value should be between 1 and 3. |
Show zero percent as 1 pixel | If set, options with 0 percent are shown as 1px line in the result. |
Include link to list of old polls | Include a link to old polls before the submit button (Text has to be set in locallang_db). |
Page to forward to after vote | Forward to specified page after successful vote. |
Multilanguage:
Option | Description |
|---|---|
Count votes for every language seperately | If checked votes are counted for every language seperately. Otherwise votes from different languages are summarized. |
Check if user can vote for every language seperately | If checked a user might vote for every language available. Otherwise the checks if a user can still vote (see General Settings) are considered for every language an the user can only vote once. |
Google Chart:
Option | Description |
|---|---|
Width | Specify the width of the image generated with Google Chart. |
Height | Specify the height of the image generated with Google Chart. |