]> sipb.mit.edu Git - ikiwiki.git/commitdiff
use POST
authorjoey <joey@0fa5a96a-9a0e-0410-b3b2-a0fd24251071>
Mon, 18 Dec 2006 16:11:51 +0000 (16:11 +0000)
committerjoey <joey@0fa5a96a-9a0e-0410-b3b2-a0fd24251071>
Mon, 18 Dec 2006 16:11:51 +0000 (16:11 +0000)
IkiWiki/Plugin/poll.pm
doc/bugs/poll_plugin_uses_GET.mdwn
doc/news/openid.mdwn

index 654d46247e10fdd2ebba87936441ddd66a0f3d5d..c040deb7622cbaa71cc9ecb6f2427aa28e3832fa 100644 (file)
@@ -45,7 +45,8 @@ sub preprocess (@) { #{{{
        my $ret="";
        foreach my $choice (@choices) {
                if ($open && exists $config{cgiurl}) {
        my $ret="";
        foreach my $choice (@choices) {
                if ($open && exists $config{cgiurl}) {
-                       $ret.="<form action=\"$config{cgiurl}\">\n";
+                       # use POST to avoid robots
+                       $ret.="<form method=\"POST\" action=\"$config{cgiurl}\">\n";
                }
                my $percent=$total > 0 ? int($choices{$choice} / $total * 100) : 0;
                $ret.="<p>\n";
                }
                my $percent=$total > 0 ? int($choices{$choice} / $total * 100) : 0;
                $ret.="<p>\n";
index adf51159a96d23e312fe483aa01f0c58e5c0baa2..0538aaa93ba915f74a87f41ae914dece1c2777ae 100644 (file)
@@ -3,4 +3,6 @@ The [[plugins/poll]] plugin uses GET for the vote links.  As a result, the
 
 done -- [[Joey]]
 
 
 done -- [[Joey]]
 
-Not quite; [the `<form>` `method` attribute defaults to GET](http://www.w3.org/TR/html401/interact/forms.html#adef-method).  The forms each need the attribute `method="POST"`.
\ No newline at end of file
+Not quite; [the `<form>` `method` attribute defaults to GET](http://www.w3.org/TR/html401/interact/forms.html#adef-method).  The forms each need the attribute `method="POST"`.
+
+[[bugs/done]] -- [[Joey]]
index cf813dfa13747e43ffe715913f80edfd2c0ebf61..f9ae0b3c997151719d59b332d7d3536117385a70 100644 (file)
@@ -10,4 +10,4 @@ log back in, try out the OpenID signup process if you don't already have an
 OpenID, and see how OpenID works for you. And let me know your feelings about
 making such a switch. --[[Joey]]
 
 OpenID, and see how OpenID works for you. And let me know your feelings about
 making such a switch. --[[Joey]]
 
-[[poll 10 "Accept only OpenID for logins" 6 "Accept only password logins" 8 "Accept both"]]
+[[poll 9 "Accept only OpenID for logins" 5 "Accept only password logins" 7 "Accept both"]]