xoopspoll

このページは旧 chikuden.info の XPWiki(2023-05-13版)を静的に復元したものです。内容は当時のままで、更新されていません。

簡単な質問項目による投票ができるXOOPSのモジュールです。

導入済みHack

説明文の表示とログの閲覧を可能とする。

説明文をつける。

●改造箇所(XOOPS 2.0.6の場合)
[1]
/html/modules/xoopspoll/class/xoopspollrenderer.php 83行目の
-----------------------------------------------------------
$tpl->assign('poll', array('question' => $this->poll->
 getVar("question"), 'pollId' => $this->poll->
 getVar("poll_id"), 'viewresults' => 
 XOOPS_URL."/modules/xoopspoll/pollresults.php?poll_id="
          .$this->poll->getVar("poll_id"), 'action' => 
 XOOPS_URL."/modules/xoopspoll/index.php", 'options' => $options));
-----------------------------------------------------------
を
-----------------------------------------------------------
$tpl->assign('poll', array('question' => $this->poll->
 getVar("question"), 'desc' => $this->poll->
 getVar("description"), 'pollId' => $this->poll->
 getVar("poll_id"), 'viewresults' => 
 XOOPS_URL."/modules/xoopspoll/pollresults.php?poll_id="
          .$this->poll->getVar("poll_id"), 'action' => 
 XOOPS_URL."/modules/xoopspoll/index.php", 'options' => $options));
-----------------------------------------------------------
に変更。
[2]
同じファイルの148行目の
-----------------------------------------------------------
$tpl->assign('poll', array('question' => $this->poll->
 getVar("question"),'end_text' => $end_text,'totalVotes' =>
 sprintf(_PL_TOTALVOTES, $total), 'totalVoters' => 
 sprintf(_PL_TOTALVOTERS, $this->poll->getVar("voters")),'vote' => 
 $vote, 'options' => $options));
-----------------------------------------------------------
を
-----------------------------------------------------------
$tpl->assign('poll', array('question' => $this->poll->
 getVar("question"),'desc' => $this->poll->
 getVar("description"),'end_text' => $end_text,'totalVotes' => 
 sprintf(_PL_TOTALVOTES, $total), 'totalVoters' => 
 sprintf(_PL_TOTALVOTERS, $this->poll->getVar("voters")),'vote' => 
 $vote, 'options' => $options));
-----------------------------------------------------------
に書き換え。

投票モジュールのログ閲覧を可能にする。

このサイトでの修正点

特になし。