[ABD] Advanced Show Poll Voters 1.0.0

Any abandoned MODs will be moved to this forum.

WARNING: MODs in this forum are not currently being supported or maintained by the original MOD author. Proceed at your own risk.
Forum rules
IMPORTANT: MOD Development Forum rules

WARNING: MODs in this forum are not currently being supported nor updated by the original MOD author. Proceed at your own risk.
Shorty1968
Registered User
Posts: 253
Joined: Sat Sep 10, 2011 10:19 am

Re: [RC] Advanced Show Poll Voters 1.0.0

Post by Shorty1968 »

watch this contribution on, as is the solution.
http://www.phpbb.com/community/viewtopi ... #p13075783

@ Camena
Here, as promised a manual:
http://www.computer-base.net/topic17.html
Sorry for my bad english,i am a German Bub and Google Translate help me. :D
yaani2
Registered User
Posts: 19
Joined: Wed Aug 17, 2011 7:57 pm

Re: [RC] Advanced Show Poll Voters 1.0.0

Post by yaani2 »

I installed the mod & went to the phpbb/install.php file.

I was going through the installation procedure & got this error
Adding acp module: acp/info/acp_polls_results.php
Fail
Everything else was successful. When I download the file containing the errors I see this
Advanced Show Poll Voters
PHP Version: 5.2.17
DBMS: MySQL 5.1.56
phpBB3 Version: 3.0.9

Adding acp module: acp/info/acp_polls_results.php
Fail
Can you please tell me what I did wrong?

Thanks!
yaani2
Registered User
Posts: 19
Joined: Wed Aug 17, 2011 7:57 pm

Re: [RC] Advanced Show Poll Voters 1.0.0

Post by yaani2 »

Never mind. I must not have added the acp/info/acp_polls_results.php file correctly. I added it & the install was successful.

Thanks!
yaani2
Registered User
Posts: 19
Joined: Wed Aug 17, 2011 7:57 pm

Re: [RC] Advanced Show Poll Voters 1.0.0

Post by yaani2 »

I installed the mod successfully.

I enabled it on the ACP General>Board Configuration>Advanced Show Poll Voters

When I go to the Permissions tab and select Groups' forum permissions & look in the forums permissions for the Administrator group. I go the Poll tab & the option "You can see who voted in the polls" is not there?

I only see Can create poll, Can vote in poll, Can change existing vote.

I checked to make sure the changes were made to the language/en/acp/permissions_phpbb.php file & I can see this line of code in that file

Code: Select all

	'acl_f_poll_results'   => array('lang'   => 'You can see who voted in the polls','cat'   => 'polls',),
Can you tell me what I may be doing wrong? OR is there something else I need to turn on to get this to work?

Thanks!
Shorty1968
Registered User
Posts: 253
Joined: Sat Sep 10, 2011 10:19 am

Re: [RC] Advanced Show Poll Voters 1.0.0

Post by Shorty1968 »

serenity15 wrote:i find solution :D

in you database find:
f_poll_results

and change number:
is_global: 1 to 0
and
is_local: o to 1

And you have permission in ACP/ Pools :D
Hello yammi2
This is the solution, generally empty after this change the "General Cache" under / the cache and look again and it should now be there.
Sorry for my bad english,i am a German Bub and Google Translate help me. :D
romeo_piter
Registered User
Posts: 130
Joined: Mon Nov 09, 2009 7:11 pm
Location: Paraguay

Re: [RC] Advanced Show Poll Voters 1.0.0

Post by romeo_piter »

Hi, having a problem with installation.
When clicking "Advanced Show Poll Voters" appears this: Cannot find module ./../includes/acp/acp_polls_results.php

I checked the installation twice. Everything is correct.
All files on their places.
Install.php was performed without any mistakes.
Shorty1968
Registered User
Posts: 253
Joined: Sat Sep 10, 2011 10:19 am

Re: [RC] Advanced Show Poll Voters 1.0.0

Post by Shorty1968 »

Hi had the same problem check the write times of white acp_polls_results.php this must acp_poll_results.php missing, the module searches a file name acp_polls_results.php your file in the folder but acp_poll_results.php with you in an s poll

to put it to make it clear

false:
acp_poll_results.php

correct:
acp_polls_results.php
Sorry for my bad english,i am a German Bub and Google Translate help me. :D
|Zotac®|
Registered User
Posts: 46
Joined: Thu Jan 06, 2011 10:57 pm

Re: [RC] Advanced Show Poll Voters 1.0.0

Post by |Zotac®| »

I have problems with this modification.
In the votes:
always 1. Jan 1970 01:00 if someone has voted.
But why?
Shorty1968
Registered User
Posts: 253
Joined: Sat Sep 10, 2011 10:19 am

Re: [RC] Advanced Show Poll Voters 1.0.0

Post by Shorty1968 »

Find in viewtopic.php

Code: Select all

    foreach ($voted_id as $option)
          {
             if (in_array($option, $cur_voted_id))
             {
                continue;
             }

             $sql = 'UPDATE ' . POLL_OPTIONS_TABLE . '
                SET poll_option_total = poll_option_total + 1
                WHERE poll_option_id = ' . (int) $option . '
                   AND topic_id = ' . (int) $topic_id;
             $db->sql_query($sql);

             if ($user->data['is_registered'])
             {
                $sql_ary = array(
                   'topic_id'         => (int) $topic_id,
                   'poll_option_id'   => (int) $option,
                   'vote_user_id'      => (int) $user->data['user_id'],
                   'vote_user_ip'      => (string) $user->ip,
                );

                $sql = 'INSERT INTO ' . POLL_VOTES_TABLE . ' ' . $db->sql_build_array('INSERT', $sql_ary);
                $db->sql_query($sql);
             }
          }
Here you have yourself one probably. still worry about the time zone on your board.
replace with:

Code: Select all

    foreach ($voted_id as $option)
          {
             if (in_array($option, $cur_voted_id))
             {
                continue;
             }

             $sql = 'UPDATE ' . POLL_OPTIONS_TABLE . '
                SET poll_option_total = poll_option_total + 1
                WHERE poll_option_id = ' . (int) $option . '
                   AND topic_id = ' . (int) $topic_id;
             $db->sql_query($sql);

             if ($user->data['is_registered'])
             {
                $sql_ary = array(
                   'topic_id'         => (int) $topic_id,
                   'poll_option_id'   => (int) $option,
                   'vote_user_id'      => (int) $user->data['user_id'],
                   'vote_user_ip'      => (string) $user->ip,
                   'vote_time'         => time(),   //Aenderungen hier
                );

                $sql = 'INSERT INTO ' . POLL_VOTES_TABLE . ' ' . $db->sql_build_array('INSERT', $sql_ary);
                $db->sql_query($sql);
             }
          }


Quelle
Sorry for my bad english,i am a German Bub and Google Translate help me. :D
|Zotac®|
Registered User
Posts: 46
Joined: Thu Jan 06, 2011 10:57 pm

Re: [RC] Advanced Show Poll Voters 1.0.0

Post by |Zotac®| »

Sorry, I'm noob in php.
Okay let me explain: I should change the date format, right?

Code: Select all

               'vote_time'         => time("j. M Y, H:i"),   //Aenderungen hier
Is it right?
(am 1. Jan 1970 01:00)
:(
Shorty1968
Registered User
Posts: 253
Joined: Sat Sep 10, 2011 10:19 am

Re: [RC] Advanced Show Poll Voters 1.0.0

Post by Shorty1968 »

Simply make the instructions from me and the date is displayed correctly.
Sorry for my bad english,i am a German Bub and Google Translate help me. :D
|Zotac®|
Registered User
Posts: 46
Joined: Thu Jan 06, 2011 10:57 pm

Re: [RC] Advanced Show Poll Voters 1.0.0

Post by |Zotac®| »

I did it. But no changes.

f_poll_results in table phpbb_acl_options
is_global: 1 to 0
and
is_local: o to 1

renamed file from acp_poll_results.php to acp_polls_results.php

and

Code: Select all

    foreach ($voted_id as $option)
          {
             if (in_array($option, $cur_voted_id))
             {
                continue;
             }

             $sql = 'UPDATE ' . POLL_OPTIONS_TABLE . '
                SET poll_option_total = poll_option_total + 1
                WHERE poll_option_id = ' . (int) $option . '
                   AND topic_id = ' . (int) $topic_id;
             $db->sql_query($sql);

             if ($user->data['is_registered'])
             {
                $sql_ary = array(
                   'topic_id'         => (int) $topic_id,
                   'poll_option_id'   => (int) $option,
                   'vote_user_id'      => (int) $user->data['user_id'],
                   'vote_user_ip'      => (string) $user->ip,
                   'vote_time'         => time(),   //Aenderungen hier
                );

                $sql = 'INSERT INTO ' . POLL_VOTES_TABLE . ' ' . $db->sql_build_array('INSERT', $sql_ary);
                $db->sql_query($sql);
             }
          }

no changes :(
serenity15
Registered User
Posts: 20
Joined: Mon Oct 31, 2011 6:14 pm

Re: [RC] Advanced Show Poll Voters 1.0.0

Post by serenity15 »

clear General Cache/ cache
|Zotac®|
Registered User
Posts: 46
Joined: Thu Jan 06, 2011 10:57 pm

Re: [RC] Advanced Show Poll Voters 1.0.0

Post by |Zotac®| »

Doesn't work :cry:
|Zotac®|
Registered User
Posts: 46
Joined: Thu Jan 06, 2011 10:57 pm

Re: [RC] Advanced Show Poll Voters 1.0.0

Post by |Zotac®| »

It is working.^^
Some other users had voted in this poll. And the date is correct. maybe.. all users voted before the installation of this mod. and one voted after the installation.

I'm -> lol

Thanks for this mod!

Return to “[3.0.x] Abandoned MODs”