index.html, cs.css i folder "im" (this page + image files),
fcounter.txt (counter value in a text file)
demo.php (sample PHP script files Voting + txt and js),
fplus.swf (file of votting component 2.5 KB),
Description of parameters:
p1 - minus less color (default 0 means cc0000 - red).
p2 - minus the value (must be an integer greater than 0 0 = does not display anything)
p3 - plus a color (default 0 means 339900 - green).
p4 - plus the value (must be an integer greater than 0 0 = does not display anything)
p5 - color of the icons (default 0 means eeeeee - light grey).
p6 - url to the PHP script adding 1 to value of plus (ex. "demo.php?vote=plus). Default value is 0 and means that, plus you can not vote (only display).
p7 - url to the PHP script adding 1 to value of minus (ex. "demo.php?vote=minus). Default value is 0 and means that less will not be able to vote (only display).
p8 - style icon buttons to vote, currently 8 styles to choose from: ("0 = circle -/+", "1 = square -/+", "2 = circle arrows", "3 = square arrows", "4 = circle x/v", "5 = square x/v", "6 = circle hands", "7 = square hands").
I decided not to use urls for voting except the last one of example were you can vote this tutorial. Other examples showing you how to change styles of component.
All parameters set to default values and no buttons to vote. style = 0 (circle - / +): "vars=0|0|0|0|0|0|0|0"
Example 2 :
The same example but we add value, less = 23 and value = 45 plus an additional set another style = 1 (square - / +): "vars=0|23|0|45|0|0|0|1"
Example 3 :
A similar example, but we change the color of icons on the bright yellow (ffff66) and we change the style of the buttons on the circle arrows: "vars=0|23|0|45|ffff66|0|0|2"
Example 4 :
In this example, replace the standard colors for negative values (333333) and plus (cccccc) and another style = 3 (square arrows) "vars=333333|23|cccccc|45|ffff66|0|0|3"
Example 5 :
Of course, no problems for colors were are the same for the plus and minus so we set the same value (993300), and let's change to another style = 4 (circle x/v): "vars=993300|23|993300|45|ffff66|0|0|4"
Example 6 :
Omitted style 5 is the same as above but in the square. 6 also omitted because the style is similar to the style of 7 which I set now (square hands). In the last example, the buttons was activated below to vote and colors was returned to standard values. You can vote for this component by clicking the button. Feedback will be visible after refresh the page. "vars=0|wartoscminusa|0|wartoscplusa|ffff66|demo.php?vote=minus|demo.php?vote=plus|7"