Commit 2719ebde authored by Dries's avatar Dries

- Bugfix: fixed problem when register globals is turned off.  Patch 0037.poll.register_globals.patch by Al.

  (Can't we make the result URL look nicer?)
parent 7f95b768
......@@ -169,7 +169,7 @@ function poll_link($type, $node = 0, $main) {
poll_allowvotes($node);
if ($node->allowvotes == 1) {
global $pollresults;
$pollresults = $_GET["pollresults"];
// Change the current URL: add/edit the value of pollresults[nid]
if ($pollresults[$node->nid]) {
......@@ -333,7 +333,7 @@ function poll_view(&$node, $main = 0, $block = 0) {
** $pollvote[nid] - A user's vote
** $pollresults[nid] - When a user hasn't voted, he can choose to see the voting form or the results
*/
global $pollresults;
$pollresults = $_GET["pollresults"];
// Make sure we have determined the 'allowvotes' flag
poll_allowvotes($node);
......
......@@ -169,7 +169,7 @@ function poll_link($type, $node = 0, $main) {
poll_allowvotes($node);
if ($node->allowvotes == 1) {
global $pollresults;
$pollresults = $_GET["pollresults"];
// Change the current URL: add/edit the value of pollresults[nid]
if ($pollresults[$node->nid]) {
......@@ -333,7 +333,7 @@ function poll_view(&$node, $main = 0, $block = 0) {
** $pollvote[nid] - A user's vote
** $pollresults[nid] - When a user hasn't voted, he can choose to see the voting form or the results
*/
global $pollresults;
$pollresults = $_GET["pollresults"];
// Make sure we have determined the 'allowvotes' flag
poll_allowvotes($node);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment