Re: pun_poll
bump x 3
You are not logged in. Please login or register.
PunBB Forums → Supported extensions → pun_poll
bump x 3
bump x 3
Huuze, isn't it very strange that no one is replying! can't we expect at least a reply whether the requested feature is going to be considered or not! Any answer is helpful! bcoz if they say 'no', then I will do it using jQuery from external extension rather than modifying poll extension!
please answer!
Thanks
@Slavok In addition to my request to have a collapsible poll, I'd also like to see the ability to select multiple answers in a poll. Many of my users will ask questions like, "Of the 5 choices, which 3 do you prefer?"
request to have a collapsible poll
Unfortunately, nobody develop this extension now. We will resolve the problem with Postgresql in the next 2-3 days. As for the collapsible poll, we will implement it in the next extension versions. Unfortunately, I can't say exactly when a new version will be released.
Pun_poll 1.1.11 is available for download!
In this version PostgreSQL compatibility problem has been resolved.
Download links:
Feel free to report more bugs
New suggestion: add info for admin to see who have voted.
add in functions.php:
function show_voted($topic_id) {
global $forum_user,$forum_db,$lang_pun_poll,$lang_topic,$forum_url;
/* select votes */
$query = array(
'SELECT' => 'user_id, answer_id',
'FROM' => 'voting',
'WHERE' => 'topic_id='.$topic_id
);
$result = $forum_db->query_build($query) or error(__FILE__, __LINE__);
while($row = $forum_db->fetch_assoc($result))
$votes[$row['user_id']] = $row['answer_id'];
/* select answer string of votes */
$answers_str = implode(',',$votes);
if(!empty($answers_str)) {
$query = array(
'SELECT' => 'id,answer',
'FROM' => 'answers',
'WHERE' => 'id in('.$answers_str.')'
);
$result = $forum_db->query_build($query) or error(__FILE__, __LINE__);
while($row = $forum_db->fetch_assoc($result))
$answers[$row['id']] = $row['answer'];
/* select user names */
$ids = implode(',',array_keys($votes));
$query = array(
'SELECT' => 'id,username,num_posts',
'FROM' => 'users',
'WHERE' => 'id in ('.$ids.')'
);
$result = $forum_db->query_build($query) or error(__FILE__, __LINE__);
while($row = $forum_db->fetch_assoc($result)) {
$names[$row['id']]['name'] = $row['username'];
$names[$row['id']]['posts'] = $row['num_posts'];
}
$return = array();
foreach($votes as $id=>$answ_id)
$return[] = '<a href="'.forum_link($forum_url['user'], $id).'" title="'.$lang_pun_poll['Voting answer'].': '.forum_htmlencode($answers[$answ_id]).'; '.$lang_topic['Posts info'].' '.$names[$id]['posts'].'">'.forum_htmlencode($names[$id]['name']).'</a>';
return implode(', ',$return);
} else return $lang_pun_poll['No voters'];
}
langfile add in end:
'No voters' => 'No voters',
manifest.xml from line 777 to 778 add
if($forum_user['is_admmod']) {
require $ext_info['path'].'/functions.php';
$main_elements['<!-- forum_main_pagepost_top -->'] .= '<div class="ct-box info-box"><p>'.show_voted($id).'</p></div>';
}
bump x 4 ...any traction on collapsing the polls by default?
bump x 4 ...any traction on collapsing the polls by default?
Im not sure if I can help but I took the spoiler code from one of the bbcode extensions and put it in pun_poll, for the same reason as you stated before.
On line 8:
<div id="spoiler-container" class="mf-box checkbox" style="border:0px solid black;">
<span id="spoiler-button" onClick="if(this.innerHTML=='Create Poll'){this.parentNode.getElementsByTagName('div')[0].style.display = 'block';this.innerHTML='Hide';} else {this.parentNode.getElementsByTagName('div')[0].style.display = 'none';this.innerHTML='Create Poll';}">Create Poll</span>
<div id="spoiler-hidebox">
<fieldset class="frm-group group<?php echo ++$forum_page['group_count'] ?>">
and on line 134:
</div></div>
I've made a few more fixes for myself and could refine them to fit in the official extensions if theres an interest in it.
Using the code below, it's not collapsed by default. It only collapses/expands if I click the "Create Poll/Hide". What should I do to tweak it?
Huuuze wrote:bump x 4 ...any traction on collapsing the polls by default?
Im not sure if I can help but I took the spoiler code from one of the bbcode extensions and put it in pun_poll, for the same reason as you stated before.
On line 8:
<div id="spoiler-container" class="mf-box checkbox" style="border:0px solid black;"> <span id="spoiler-button" onClick="if(this.innerHTML=='Create Poll'){this.parentNode.getElementsByTagName('div')[0].style.display = 'block';this.innerHTML='Hide';} else {this.parentNode.getElementsByTagName('div')[0].style.display = 'none';this.innerHTML='Create Poll';}">Create Poll</span> <div id="spoiler-hidebox"> <fieldset class="frm-group group<?php echo ++$forum_page['group_count'] ?>">
and on line 134:
</div></div>
I've made a few more fixes for myself and could refine them to fit in the official extensions if theres an interest in it.
Hi,
Foremost, thanks you !
Bug report : Multiple twices " in FORUM_ROOT.'extensions/pun_poll/functions.php';
---------------
line 9 :
<div class="sf-set set<?php echo ++$forum_page['item_count'] ?>"">
line 37 :
<div class="sf-set set<?php echo ++$forum_page['item_count'] ?>"">
line 81 :
<div class="sf-set set<?php echo ++$forum_page['item_count'] ?>"">
line 94 :
<div class="sf-set set<?php echo ++$forum_page['item_count'] ?>"">
Edit: I just found another bug, I'm looking to rectify that immediately
<th> misplaced in <table>. Creating <tr> and putting <th> inside it.
Reedit :
If you want ...
I made the change in the file, i have corrected too manifest and i have changed : version to 1.1.12, maxtestedon to 1.3.4.
I uploaded the edited file here : http://punbb.informer.com/wiki/_media/p … n_poll.zip
Regards.
Bump ... anyone?
include some poll id on index ?
Any chance to have these bars in a future 1.3 version release?
Bug
When I create a poll as a user, I can edit the questions afterwards as admin but, when I try to change the post text as admin and click Submit, the text is back as it was.
It works when the user himself edit his own post. It makes it impossible for an admin to moderate a post with a poll.
No, in version for PunBB 1.3 only bugfixes.
tomi0, please try this updated version of pun poll — pun_poll-1.1.11.zip
1.1.11 is already the version I use, is that zip a modified one?
If yes, I can I update without uninstalling my previous pun_poll version (don't want to lose my existing polls )
Thanks
Strange, but use pun_poll-1.1.12.zip
Ready to test but...
How can I update it without deleting my current polls? Any procedure to update extensions?
Safe method
Disable pun_poll on extensions page.
Remove or move current pun_poll folder from extensions dir.
Copy new pun_poll to extension dir.
Update pun_poll on extensions page.
Enable pun_poll on extensions page.
Upgraded, tested, and approved.
I confirm the bug is fixed, Admins and Moderators can now edit posts containing Poll.
Thank you for your great support dimka
I've problems starting a poll with extension version v2.3. My PunBB version is 1.4.1. The installation of the poll extension worked fine but if I want to start a new poll there is just the text "Show poll block" without a checkbox or place to add text under my thread window. Can anyone give me a hint?
Screenshot: http://imageshack.us/photo/my-images/82 … oblem.jpg/
I got the extension from punbb.informer.com/extensions/1.4/pun_poll/pun_poll.tgz
Is this the latest and correct version?
thanks and regards,
magmer
PunBB Forums → Supported extensions → pun_poll
Powered by PunBB, supported by Informer Technologies, Inc.