Simple Machines Community Forum

Customizing SMF => Modifications and Packages => Topic started by: Søren Bjerg on August 30, 2006, 09:25:16 PM

Title: Who Voted What?
Post by: Søren Bjerg on August 30, 2006, 09:25:16 PM
Link to Mod (http://mods.simplemachines.org/index.php?mod=347)
Rate this Mod (http://mods.simplemachines.org/index.php?action=review;sa=add;mod=347)

"Who Voted What?" allows people with sufficient permissions to see which members voted for what option in a poll.

Screenshot: http://www.sorenbjerg.dk/images/smf_mod_whovotedwhat.jpg
Title: Re: Who Voted What?
Post by: Nic- on September 04, 2006, 12:17:31 PM
thank you , useful mod  ;)
Title: Re: Who Voted What?
Post by: LostProphecy on September 07, 2006, 06:48:09 PM
ooooh and to think i don't have to go searching in the database anymore to discovered who voted for what :)
Title: Re: Who Voted What?
Post by: JustJen on September 11, 2006, 02:26:49 PM
It doesn't seem to work for me.
Title: Re: Who Voted What?
Post by: Søren Bjerg on September 12, 2006, 09:02:51 AM
Quote from: Ajen on September 11, 2006, 02:26:49 PM
It doesn't seem to work for me.
Won't work as in won't install or won't display anything after installation?
Title: Re: Who Voted What?
Post by: corruptor on September 12, 2006, 03:08:07 PM
After succesful install, noting appears to happen.
What should I expect?
Title: Re: Who Voted What?
Post by: Harzem on September 12, 2006, 03:10:37 PM
Maybe you can write a note to the first post of this topic that this mod ONLY works for 1.1 series...
Title: Re: Who Voted What?
Post by: corruptor on September 12, 2006, 03:25:44 PM
Quote from: HarzeM on September 12, 2006, 03:10:37 PM
Maybe you can write a note to the first post of this topic that this mod ONLY works for 1.1 series...

I am not sure I follow you cheif...

QuoteLatest Version: 1.1
Compatible With: 1.1 RC2, 1.1 RC3

I am using 1.1 RC3...
Please explain.
Title: Re: Who Voted What?
Post by: Søren Bjerg on September 12, 2006, 03:30:36 PM
Quote from: corruptor on September 12, 2006, 03:08:07 PM
After succesful install, noting appears to happen.
What should I expect?
If I remember correctly, the mod is setup to display the voters to members per default - otherwise check your membergroup permissions and check if it's present ('View voters' under 'Poll').

It adds the selectboxes right of the normal poll display in a topic with a poll attached to it.

Quote from: HarzeM on September 12, 2006, 03:10:37 PM
Maybe you can write a note to the first post of this topic that this mod ONLY works for 1.1 series...
The modification page already says "Compatible With:     1.1 RC2, 1.1 RC3", but sure... can do if you think so.
Title: Re: Who Voted What?
Post by: corruptor on September 12, 2006, 03:49:30 PM
I am viewing from the admin account and permissions is set to (all)
I also tried a moderator account and checked the 'view voters' box there. Still no change.

screen shot (http://www.theindelible.com/files/screen.png)
Title: Re: Who Voted What?
Post by: Søren Bjerg on September 12, 2006, 03:52:47 PM
Try checking your Display.php file to verify the modification has been fully installed, by comparing it to the contents of the modification.xml file.
Title: Re: Who Voted What?
Post by: corruptor on September 12, 2006, 04:17:44 PM
It appears to have made the modifications.
www.theindelible.com/files/Display.txt

So I am still at a loss as to why it is not working.

edit: BTW, thank you for your support!!!
Title: Re: Who Voted What?
Post by: Søren Bjerg on September 13, 2006, 01:51:11 AM
I think I might have gotten it now... you're using a custom theme, right? In that case, it probably hasn't added the modifications to the Display.template.php in your theme directory.

Try seeing if it works as supposed to with the default theme :).

If it doesn't, I'm afraid I'm as cluesless as to why it's not working, as you are :/.
Title: Re: Who Voted What?
Post by: Vinspire on September 13, 2006, 06:50:57 AM
Awesome mod ! Been waiting for this mod for a very long time. Now it make my life easier as I know which mod had cast a vote or not.

Just installed this mod and it work smoothly.

Anyway, only admin can view who casted the vote right ?
Title: Re: Who Voted What?
Post by: Søren Bjerg on September 13, 2006, 08:40:48 AM
Quote from: Vinspire on September 13, 2006, 06:50:57 AM
[...] Anyway, only admin can view who casted the vote right ?
It's driven by permissions, so only administrators can see it if that's how you set it up :).
Title: Re: Who Voted What?
Post by: Vinspire on September 13, 2006, 10:27:41 AM
Quote from: Søren Bjerg on September 13, 2006, 08:40:48 AM
Quote from: Vinspire on September 13, 2006, 06:50:57 AM
[...] Anyway, only admin can view who casted the vote right ?
It's driven by permissions, so only administrators can see it if that's how you set it up :).

driven by permissions ? I just make a clean install on the mod and everything is working well and when i check the member permission area ... I don't see any place I could "tick" for this permission to view who make the vote  :-\
Title: Re: Who Voted What?
Post by: Søren Bjerg on September 13, 2006, 10:36:44 AM
You should find a 'View voters' option under 'Poll'.
Title: Re: Who Voted What?
Post by: Vinspire on September 13, 2006, 10:53:51 AM
Yeap. I saw it. Thank you !!!

(https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fimg155.imageshack.us%2Fimg155%2F9246%2Fvpollgh6.png&hash=9792f80f05ebfc2f9c604be1299bbb0922797d11)
Title: Re: Who Voted What?
Post by: usvi4me on September 13, 2006, 10:57:14 AM
Quote from: Søren Bjerg on September 13, 2006, 01:51:11 AM
I think I might have gotten it now... you're using a custom theme, right? In that case, it probably hasn't added the modifications to the Display.template.php in your theme directory.

Try seeing if it works as supposed to with the default theme :).

If it doesn't, I'm afraid I'm as cluesless as to why it's not working, as you are :/.

This mod does not install properly when you use a theme other than default.
I have the Amber theme as default.  In permissions the view result option shows up.  When checked for a group, no dropdown boxes are displayed - yet the option in Permissions is there.
I uninstalled the mod, set up the forum with the default theme and re-installed the mod. YES, it works.  Then re-installed the theme and the post result dropdowns are GONE.

Any suggestions as to what I need to change for the AMBER theme ?

Title: Re: Who Voted What?
Post by: Vinspire on September 13, 2006, 01:00:58 PM
Quote from: usvi4me on September 13, 2006, 10:57:14 AM
Quote from: Søren Bjerg on September 13, 2006, 01:51:11 AM
I think I might have gotten it now... you're using a custom theme, right? In that case, it probably hasn't added the modifications to the Display.template.php in your theme directory.

Try seeing if it works as supposed to with the default theme :).

If it doesn't, I'm afraid I'm as cluesless as to why it's not working, as you are :/.

This mod does not install properly when you use a theme other than default.
I have the Amber theme as default.  In permissions the view result option shows up.  When checked for a group, no dropdown boxes are displayed - yet the option in Permissions is there.
I uninstalled the mod, set up the forum with the default theme and re-installed the mod. YES, it works.  Then re-installed the theme and the post result dropdowns are GONE.

Any suggestions as to what I need to change for the AMBER theme ?

Almost every mods won't work perfectly in a custom theme. You need to modify the file manually.

I can't find the thread about how to make mods work with custom theme  :-\
Title: Re: Who Voted What?
Post by: corruptor on September 13, 2006, 01:08:26 PM
Quote from: Vinspire on September 13, 2006, 01:00:58 PM
Quote from: usvi4me on September 13, 2006, 10:57:14 AM
Quote from: Søren Bjerg on September 13, 2006, 01:51:11 AM
I think I might have gotten it now... you're using a custom theme, right? In that case, it probably hasn't added the modifications to the Display.template.php in your theme directory.

Try seeing if it works as supposed to with the default theme :).

If it doesn't, I'm afraid I'm as cluesless as to why it's not working, as you are :/.

This mod does not install properly when you use a theme other than default.
I have the Amber theme as default.  In permissions the view result option shows up.  When checked for a group, no dropdown boxes are displayed - yet the option in Permissions is there.
I uninstalled the mod, set up the forum with the default theme and re-installed the mod. YES, it works.  Then re-installed the theme and the post result dropdowns are GONE.

Any suggestions as to what I need to change for the AMBER theme ?

Almost every mods won't work perfectly in a custom theme. You need to modify the file manually.

I can't find the thread about how to make mods work with custom theme  :-\

This is the single most frustrating fact about mods!
There needs to be a way simplify this by using a standard or keeping things consitant.
I tried to modify the files manually but got errors. I am not a programmer, and reading lines of code is not fun to me. (my problem, I know)
I am scared I will mess up a working site... (yes I make backups)
If anyone can help, I would love you forever for it. ( i know, you are all excited about that!  ::)  )
Title: Re: Who Voted What?
Post by: usvi4me on September 13, 2006, 01:37:54 PM

Quote

This is the single most frustrating fact about mods!
There needs to be a way simplify this by using a standard or keeping things consitant.
I tried to modify the files manually but got errors. I am not a programmer, and reading lines of code is not fun to me. (my problem, I know)
I am scared I will mess up a working site... (yes I make backups)
If anyone can help, I would love you forever for it. ( i know, you are all excited about that!  ::)  )

For now this is my resolution as I really WANT this mod.

When I need to look at a poll and find out who voted what, I set the server mode in maintenance for a few minutes, change to the default theme and check the results.  Then ofcourse I have to remember to set it back to MY preferred theme and take it out of maintenance mode.

Maybe Soren will find us a fix ......
Title: Re: Who Voted What?
Post by: corruptor on September 13, 2006, 01:44:39 PM
My purpose is a little different. I intend to use this mod to show availability of other players for an event.
For example,
Poll: Who is available for scrim tonight?
Available ----------------------------------100% joe, jim, josh, jack
Not available-----0%

So I need this to work in my theme as it matches the site. Plus all the editing I have done to the theme, grrr.

I really would like this mod as well. There are others that I have to live without since they only work with default mod. Again, this is soooo frustrating.
Title: Re: Who Voted What?
Post by: Vinspire on September 13, 2006, 01:49:22 PM
Quote from: corruptor on September 13, 2006, 01:08:26 PM
This is the single most frustrating fact about mods!
There needs to be a way simplify this by using a standard or keeping things consitant.
I tried to modify the files manually but got errors. I am not a programmer, and reading lines of code is not fun to me. (my problem, I know)
I am scared I will mess up a working site... (yes I make backups)
If anyone can help, I would love you forever for it. ( i know, you are all excited about that!  ::)  )

Quote from: usvi4me on September 13, 2006, 01:37:54 PM
For now this is my resolution as I really WANT this mod.

When I need to look at a poll and find out who voted what, I set the server mode in maintenance for a few minutes, change to the default theme and check the results.  Then ofcourse I have to remember to set it back to MY preferred theme and take it out of maintenance mode.

Maybe Soren will find us a fix ......

The thing is this is not Soren fault. He can't modified every single themes in SMF Board you know ?  :-\

Anyway, I've highlighted out what you guys need to do.

What you need to do to get it to work on other theme is modified Display.template.php and Modifications.english.php

P/S : Remember to make a backup copy of this file before you modified it :)

Display.template.php

Search for

![CDATA[ // Show each option with its corresponding percentage bar.
foreach ($context['poll']['options'] as $option)
echo '
<tr>
<td style="padding-right: 2ex;', $option['voted_this'] ? 'font-weight: bold;' : '', '">', $option['option'], '</td>', $context['allow_poll_view'] ? '
<td nowrap="nowrap">' . $option['bar'] . ' ' . $option['votes'] . ' (' . $option['percent'] . '%)</td>' : '', '
</tr>';


Replace that code with this

![CDATA[ // Show each option with its corresponding percentage bar.
foreach ($context['poll']['options'] as $option)
{
echo '
<tr>
<td style="padding-right: 2ex;', $option['voted_this'] ? 'font-weight: bold;' : '', '">', $option['option'], '</td>', $context['allow_poll_view'] ? '
<td nowrap="nowrap">' . $option['bar'] . ' ' . $option['votes'] . ' (' . $option['percent'] . '%)</td>' : '', '';
        // [Who Voted What?]
        if (allowedTo('poll_view_voters'))
        {
          echo '
  <td style="padding-left: 2ex;">
                    <select name="voters' . $option['ID_OPTION'] . '" id="jumpto" onchange="if (this.selectedIndex > 0 &amp;&amp; this.options[this.selectedIndex].value) window.location.href = smf_scripturl + this.options[this.selectedIndex].value.substr(smf_scripturl.indexOf(\'?\') == -1 || this.options[this.selectedIndex].value.substr(0, 1) != \'?\' ? 0 : 1);" style="width: 150px;">';
          if (!empty($context['poll']['options'][$option['ID_OPTION']]['voters']))
          {
            echo '
                      <option selected="selected" value="#">' . $txt['poll_view_voters_expand_to_view'] . '</option>
                      <option disabled="disabled" value="">----------------------</option>';
            foreach ($context['poll']['options'][$option['ID_OPTION']]['voters'] as $voter)
            {
              echo '
                      <option value="?action=profile;u=' . $voter['ID_MEMBER'] . '"> => ' . $voter['realName'] . '</option>';
            }
            echo '
                      <option disabled="disabled" value="">----------------------</option>
                      <option disabled="disabled" value="">' . $txt['poll_view_voters_expanded_help1'] . '</option>
                      <option disabled="disabled" value="">' . $txt['poll_view_voters_expanded_help2'] . '</option>';

          } else
          {
            echo '
                      <option disabled="disabled" selected="selected" value="">----------------------</option>';
          }
          echo '
                    </select>
                  </td>
          ';
        }
        echo '
</tr>';
}


Then go to your theme language folder look for Modifications.english.php file

Search

position="end"

Add this code before that code

![CDATA[// [Who Voted What?]
$txt['poll_view_voters_expand_to_view'] = 'Expand to view:';
$txt['poll_view_voters_expanded_help1'] = 'Select a name to view';
$txt['poll_view_voters_expanded_help2'] = 'the member\'s profile...';
$txt['cannot_poll_view_voters'] = 'Sorry, you\'re not allowed to view which members voted for what option in the poll.';
$txt['permissionname_poll_view_voters'] = 'View voters';
$txt['permissionhelp_poll_view_voters'] = 'This permission allows people to see which members voted for what option in a poll.';
Title: Re: Who Voted What?
Post by: corruptor on September 13, 2006, 02:23:07 PM
Well I tried this, but I gete a php error.

The problem is, there is no "Modifications.english.php" in any of the 5 themes I have. This only exist in the default theme.

I even tried putting a copy in my theme folder.

I did confirm it does work fine with my default theme. Nice mod. I would like to see the name listed instead of a pull down.

Thanks for your help man, but I am about to give up...
Title: Re: Who Voted What?
Post by: Vinspire on September 13, 2006, 02:27:06 PM
Quote from: corruptor on September 13, 2006, 02:23:07 PM
Well I tried this, but I gete a php error.

The problem is, there is no "Modifications.english.php" in any of the 5 themes I have. This only exist in the default theme.

I even tried putting a copy in my theme folder.

I did confirm it does work fine with my default theme. Nice mod. I would like to see the name listed instead of a pull down.

Thanks for your help man, but I am about to give up...

What is the error ? No "Modifications.english.php" then create one file with that name put in the code and create a "language" folder under ur theme .... After that copy and put in "Modifications.english.php" onto that folder.
Title: Re: Who Voted What?
Post by: Søren Bjerg on September 13, 2006, 02:33:17 PM
I'm afraid the (great) advice Vinspire has been giving is about as much advice I could give to get it running with a custom theme as well.

As for having the names listed on the page instead of the select box, I did play around with ways of displaying it such in a neat way, but it didn't work out too nicely for me, so I ended up with the select box.
Title: Re: Who Voted What?
Post by: Vinspire on September 13, 2006, 02:35:50 PM
Quote from: Søren Bjerg on September 13, 2006, 02:33:17 PM
I'm afraid the (great) advice Vinspire has been giving is about as much advice I could give to get it running with a custom theme as well.

As for having the names listed on the page instead of the select box, I did play around with ways of displaying it such in a neat way, but it didn't work out too nicely for me, so I ended up with the select box.

Soren, I like the way you put it in the "dropdown menu" ... It is awesome. look superneat  ;D

I prefer it more than having it listed out straight away coz if there is too many ppls casting the vote than all my poll would look super messy  >:(
Title: Re: Who Voted What?
Post by: corruptor on September 13, 2006, 02:37:27 PM
www.theindelible.com/files/phperror.png

not sure why it faile on an else statement...
Title: Re: Who Voted What?
Post by: usvi4me on September 13, 2006, 02:53:31 PM
I did get it to work with the amber theme.  Thank you.

Created a languages directory in the amber theme directory.
Since the default theme was working, i just copied the  modifications.english.php file in the Amber/Languages directory.

The Amber Display.template.php did not have the [Data so i searched for "Show each option with its corresponding percentage bar" and replaced with the text as posted earlier.

Thank you, thank you ....
         
                        
                     
Title: Re: Who Voted What?
Post by: J!ass on October 05, 2006, 11:05:01 AM
Got a problem with the permissions.
I set the permission for "regular users" as I have to, that they can see the voters but nothing appers.

The two Admins can see the voters.
Title: Re: Who Voted What?
Post by: HecKel on October 23, 2006, 12:19:46 PM
Hi!

I like this mod :) But, is any change to enhance this to be more eye candy? For exemple, like VBulletin boards!

Another idea, why not create a new poll type? If the votes were public, so anybody can see who voted what, else, only who can moderate that board can see that! (like VBulletin too)

HecKel
Title: Re: Who Voted What?
Post by: Søren Bjerg on October 26, 2006, 09:28:17 AM
I did try various ways of displaying the names of the voters in a pretty manner, but this was what I ended up with eventually.

Might work on it a bit sometime in near/distant future.
Title: Re: Who Voted What?
Post by: littleone on October 27, 2006, 06:47:23 PM
I have this installed and gave my moderator membergroup the permissions to see however they cant see who voted what.  So my question is what is the problem?  (I can see them though ;) )
Title: Re: Who Voted What?
Post by: Søren Bjerg on October 28, 2006, 06:45:31 PM
If the permissions are set up properly and you're using the default theme, I have no idea what could be causing it to malfunction for you.
Title: Re: Who Voted What?
Post by: littleone on October 28, 2006, 08:28:02 PM
Yup the permission is enabled and I am on default theme
Title: Re: Who Voted What?
Post by: Vinspire on October 29, 2006, 10:21:35 PM
Quote from: littleone on October 28, 2006, 08:28:02 PM
Yup the permission is enabled and I am on default theme

Is your forummers on SMF default theme too ?
Title: Re: Who Voted What?
Post by: littleone on October 30, 2006, 04:56:52 PM
Thats the only theme I have enabled.
Title: Re: Who Voted What?
Post by: MoreBloodWine on November 10, 2006, 04:37:50 PM
Two thumbs up on this one... I integrated it just fine into my custom theme... all works as expected for now...
Title: Re: Who Voted What?
Post by: lemur21 on December 04, 2006, 06:39:04 PM
Hello,

With 1.1 Final out -- is there an ETA on when the 1.1 compatible version of this mod will be ready?

This is probably my favorite mod, and we use the polls on my board for a ton of research...

Thanks!!

Chris
Title: Re: Who Voted What?
Post by: JustJen on December 04, 2006, 06:48:25 PM
We use it too. Patiently waiting!!
Title: Re: Who Voted What?
Post by: growwl on December 05, 2006, 05:25:21 AM
i've been trying to mod the mod and chandged 1.1 RC2, 1.1 RC3 in the package-info.xml to ...1.1 RC3, 1.1
but since i did that and tried to zip the two files of the package and upload them, i get an error that says that the package is corrupt or not valid.

if i try to use the unmodified package of the mod i get an error that says "no actions defined".

so what?
anyone a idea how to fix that to use this terrific mod with smf 1.1 final?
Title: Re: Who Voted What?
Post by: Søren Bjerg on December 05, 2006, 05:49:18 AM
Adding ", 1.1" to the list of compatible versions does work, as that's how I did it on my own installation of the modification.

I've uploaded the updated version I used myself to the download page.
Title: Re: Who Voted What?
Post by: growwl on December 05, 2006, 05:55:38 AM
hi soren!
thanks a lto for the quick reply!
Title: Re: Who Voted What?
Post by: Hexjackal on December 05, 2006, 07:29:32 PM
The mod isn't working. I'm using the latest version of the mod with SMF 1.1. Is there an option I need to enable or something?
Title: Re: Who Voted What?
Post by: Søren Bjerg on December 06, 2006, 01:24:59 AM
You enable it for the membergroups allowed to see the voters by enabling them the permission (View voters) for it.
Title: Re: Who Voted What?
Post by: growwl on December 06, 2006, 06:56:29 AM
hi Søren!

is there also a possibility to show the results in a table and not with the dropdown boxes?
Title: Re: Who Voted What?
Post by: Søren Bjerg on December 06, 2006, 07:23:18 AM
I think I did promise some time ago to look into alternative ways of presenting the results... but I havn't gotten around to it yet :-[.

I'll see what I can do. What you're looking for is how vBulletin does it, right?
Title: Re: Who Voted What?
Post by: growwl on December 06, 2006, 07:38:34 AM
hi soren!
i don't even know how vbvulletin does it, i only wished the resultas were printed / echoed in a way that is easier to read.

your mod is great, but you always have to click through the dropdown boxes in order to see who voted what.
so, as for me, a simple table where the results are presented would be great!
Title: Re: Who Voted What?
Post by: Krysia on December 06, 2006, 06:43:00 PM
Very nice mod, thank you. :)

It did install half-automatically, with me doing the rest by hand. Works great with my custom theme.
Thanks again! :)
Title: Re: Who Voted What?
Post by: growwl on December 12, 2006, 03:57:01 AM
hi soren!

any news about the other kind of showing the results(table)?
Title: Re: Who Voted What?
Post by: Søren Bjerg on December 12, 2006, 06:55:45 AM
Sorry, been rather busy lately, but I'll see if I can find time to try something out after work today.
Title: Re: Who Voted What?
Post by: Søren Bjerg on December 12, 2006, 04:07:16 PM
Ok, here's a sort of work in progress version (it could use some touching up) with a tabled view of the results as opposed to the select boxes. It's only got native 1.1 final support, but I doubt it'd fail to function if the package_info file was modified to install on previous 1.1 versions.

who_voted_what_1-1_alternative.zip (http://mods.simplemachines.org/index.php?action=download;mod=347;id=22365)

Optimally, the two of the releases should be merged into a single release - with a choice of which of the results views to be used.

Hope it works for you :-[!
Title: Re: Who Voted What?
Post by: JustJen on December 12, 2006, 04:47:14 PM
I enabled the permissions, but I am not seeing the results.  ???
Title: Re: Who Voted What?
Post by: growwl on December 13, 2006, 02:20:55 AM
hi soren!
great work, i appreciate that.
thank you so much!!!
Title: Re: Who Voted What?
Post by: Syndel on December 13, 2006, 04:19:58 PM
Ok... HELP! *L*
I absolutely LOVE LOVE your Mod... but... since the upgrade to 1.1, after redownloading the Mod and reinstalling (without errors, mind you) I have this thing on the top of my board and hell.. I do not find it to get rid of it... I looked at the index.template... at the display.template... at the messages.index... I looked everywhere before coming to pester... but... I need your help...


Quote// Avatars at Index Mod By alperuzi $txt['enable_mini_avatars'] = 'Enable displaying mini avatars at message index'; $txt['miniAvatarHeight'] = 'Avatar height (pixels)'; $txt['miniAvatarWidth'] = 'Avatar width (pixels)'; // End Of Avatars at Index Mod // [Who Voted What?] $txt['poll_view_voters_expand_to_view'] = 'Expand to view:'; $txt['poll_view_voters_expanded_help1'] = 'Select a name to view'; $txt['poll_view_voters_expanded_help2'] = 'the member\'s profile...'; $txt['cannot_poll_view_voters'] = 'Sorry, you\'re not allowed to view which members voted for what option in the poll.'; $txt['permissionname_poll_view_voters'] = 'View voters'; $txt['permissionhelp_poll_view_voters'] = 'This permission allows people to see which members voted for what option in a poll.'; // Avatars at Index Mod By alperuzi $txt['enable_mini_avatars'] = 'Enable displaying mini avatars at message index'; $txt['miniAvatarHeight'] = 'Avatar height (pixels)'; $txt['miniAvatarWidth'] = 'Avatar width (pixels)'; // End Of Avatars at Index Mod

You can check for yourself here: www.khaotikdezirez.com

Help!
Title: Re: Who Voted What?
Post by: Syndel on December 13, 2006, 04:40:10 PM
http://www.simplemachines.org/community/index.php?topic=134294

Was fixed... was in the Languages> Modifications.English.php  the problem...
Title: Re: Who Voted What?
Post by: Søren Bjerg on December 14, 2006, 01:47:40 AM
Quote from: Ajen on December 12, 2006, 04:47:14 PM
I enabled the permissions, but I am not seeing the results.  ???
If you're using the default theme, and the modification installed successfully, I'm afraid I have no idea what could be causing it to malfunction :-[. It worked flawlessly on a stock 1.1 final when developing it.

Quote from: Syndel on December 13, 2006, 04:40:10 PM
[...]
Good to hear you found a fix for it. I would have been pretty stumped at finding what was causing it myself :-[.
Title: Re: Who Voted What?
Post by: growwl on December 14, 2006, 06:04:13 AM
hi soren!
one more question to your "modded-mod".

when trying to adjust the table to my needs, it was no problem to alter the font size for the voters displayed, but when trying to change the background color or image of specific columns, there's no effect.
is that due to the forum's theme's css that is used and overriding the specific tags in the table?
Title: Re: Who Voted What?
Post by: JustJen on December 14, 2006, 01:57:52 PM
Quote from: growwl on December 14, 2006, 06:04:13 AM
hi soren!
one more question to your "modded-mod".

when trying to adjust the table to my needs, it was no problem to alter the font size for the voters displayed, but when trying to change the background color or image of specific columns, there's no effect.
is that due to the forum's theme's css that is used and overriding the specific tags in the table?

Duh, I am an idiot. It works perfectly in the default theme. Very nice work!  :D
Title: Re: Who Voted What?
Post by: VividViews on December 19, 2006, 04:19:34 PM
I love this mod and tried it using 1.1 RC3 then 1.1 final.  But now I have a clean install of SMF 1.1.1 and this mod can't be installed anymore.  I tried tweaking the packageinfo to add 1.1.1 for the install version but ultimately got a parse error so I stopped my effort.

Can this be updated to work with SMF 1.1.1?   BIG thanks.
Title: Re: Who Voted What?
Post by: Søren Bjerg on December 19, 2006, 04:23:59 PM
I'll probably get around to do something about it tomorrow...

EDIT: I promise I'll fix it up this upcoming week, not having to go to work... going to merge the two alternatives into a single package as well.
Title: Re: Who Voted What?
Post by: kriskd on December 30, 2006, 07:16:33 AM
Quote from: Søren Bjerg on December 19, 2006, 04:23:59 PM
I'll probably get around to do something about it tomorrow...

EDIT: I promise I'll fix it up this upcoming week, not having to go to work... going to merge the two alternatives into a single package as well.

I'm new to this mod and after reading through this will wait to install it until these little things are fixed and the merge of the two alternatives takes place. 

Thanks for your hard work, Søren!
Title: Re: Who Voted What?
Post by: Søren Bjerg on December 30, 2006, 08:16:23 AM
Alright, working on the modification... but seems like the 1.1 release should work out of the box for SMF 1.1.1. Couldn't find any changes in the search parameters, and it works nicely on a fresh SMF 1.1.1 installation, but oh well... working on merging the two 1.1 releases then :).
Title: Re: Who Voted What?
Post by: Søren Bjerg on December 30, 2006, 09:24:47 AM
An updated version for 1.1.1 (native support for 1.1.1 only) is now available - hope it works (it did on my fresh locally installed SMF 1.1.1, mind)!

http://mods.simplemachines.org/index.php?mod=347
Title: Re: Who Voted What?
Post by: kriskd on December 30, 2006, 02:45:02 PM
Okay, slight problem... after I vote, the results are not available even though "Show the poll's results to anyone" is selected.  Am I just missing something?
Title: Re: Who Voted What?
Post by: kriskd on December 30, 2006, 02:49:07 PM
Okay, slight correction, I changed it to "table view" and it seems to work properly.  Is the "select box" option not supposed to show how the voting is going to anyone?  How and where can the admin get the results and who voted for what with this view?
Title: Re: Who Voted What?
Post by: kriskd on December 30, 2006, 03:00:52 PM
Okay, sorry about that, I needed to put the various text variables in my index.english.php file and now the select boxes are working at they should. I might have to mess around with the colors because the gray at the bottom of the select boxes doesn't show up well in my template.

Again, great mod!
Title: Re: Who Voted What?
Post by: DaBoROE09 on December 30, 2006, 03:17:33 PM
i can not get this to work properly...can someone please help me i would like to know this being the admin and owner of the website.
Title: Re: Who Voted What?
Post by: Loverboy on December 30, 2006, 06:41:48 PM
Quote from: kriskd on December 30, 2006, 02:45:02 PM
Okay, slight problem... after I vote, the results are not available even though "Show the poll's results to anyone" is selected.  Am I just missing something?

I've got the same problems .. could you explain how you fixed it all?
Title: Re: Who Voted What?
Post by: kriskd on December 30, 2006, 09:05:58 PM
Quote from: Loverboy on December 30, 2006, 06:41:48 PM
I've got the same problems .. could you explain how you fixed it all?

No problem.  :)

You need to put the following in your index.english.php file which can be found in your default/languages file.


// [Who Voted What?]
$txt['poll_view_voters_expand_to_view'] = 'Expand to view:';
$txt['poll_view_voters_expanded_help1'] = 'Select a name to view';
$txt['poll_view_voters_expanded_help2'] = 'the member\'s profile...';
$txt['cannot_poll_view_voters'] = 'Sorry, you\'re not allowed to view which members voted for what option in the poll.';
$txt['permissionname_poll_view_voters'] = 'View voters';
$txt['permissionhelp_poll_view_voters'] = 'This permission allows people to see which members voted for what option in a poll.';
$txt['whovotedwhatMode'] = 'Who Voted What? mode';
$txt['whovotedwhatMode0'] = 'Select Box';
$txt['whovotedwhatMode1'] = 'Table View';


I've had to add other variables to this file with other mods and prefer to put them at the end where I can easily find them should I have to uninstall a mod at some point in the future.
Title: Re: Who Voted What?
Post by: Loverboy on January 01, 2007, 04:33:20 PM
It still does not show the results
Title: Re: Who Voted What?
Post by: RoarinRow on January 01, 2007, 06:00:33 PM
Quote from: kriskd on December 30, 2006, 09:05:58 PM
Quote from: Loverboy on December 30, 2006, 06:41:48 PM
I've got the same problems .. could you explain how you fixed it all?

No problem.  :)

You need to put the following in your index.english.php file which can be found in your default/languages file.


// [Who Voted What?]
$txt['poll_view_voters_expand_to_view'] = 'Expand to view:';
$txt['poll_view_voters_expanded_help1'] = 'Select a name to view';
$txt['poll_view_voters_expanded_help2'] = 'the member\'s profile...';
$txt['cannot_poll_view_voters'] = 'Sorry, you\'re not allowed to view which members voted for what option in the poll.';
$txt['permissionname_poll_view_voters'] = 'View voters';
$txt['permissionhelp_poll_view_voters'] = 'This permission allows people to see which members voted for what option in a poll.';
$txt['whovotedwhatMode'] = 'Who Voted What? mode';
$txt['whovotedwhatMode0'] = 'Select Box';
$txt['whovotedwhatMode1'] = 'Table View';


I've had to add other variables to this file with other mods and prefer to put them at the end where I can easily find them should I have to uninstall a mod at some point in the future.

Actually, the file I modified was the Modification.english.php file.

I found that the package did not place the new code in the right place.  I found this before the code:

?>
// [Who Voted What?] . . .

I removed the ?> and put it at the end of the file instead of the beginning of the code.  That removed the text from top of the forum and made the mod work. 
Title: Re: Who Voted What?
Post by: Ninoslav on January 07, 2007, 11:00:42 AM
I keep getting the

8: Undefined index: whovotedwhatMode
File: home\newsmf\Themes\default\Display.template.php (main sub template - eval?)
Line: 47

error... can you see what it is?
Title: Re: Who Voted What?
Post by: Søren Bjerg on January 07, 2007, 12:51:48 PM
I could imagine it had something to do with the text definitions not being added to the language file, but as don't really know the ins-and-outs of how the system works, I can't say for sure...
Title: Re: Who Voted What?
Post by: Ninoslav on January 07, 2007, 01:45:20 PM
So there is no chance :(

EDIT: I've switched to table view and it works! Good enough for me!
Title: Re: Who Voted What?
Post by: lemur21 on January 22, 2007, 12:36:59 PM
I've got an interesting dilemma --

I upgraded my theme, so I uninstalled all my mods and reinstalled them when the theme was upgraded.

Most of the mods work 100% fine -- this one does too, basically.

But, for some reason, now, when I view the poll responders, it lists every twice. Not in order, per se...

If, for example, before, my responders were:

Bill
Frank
John

Now, the responders read:

Bill
Frank
John
Bill
Frank
John

Any idea what happened here, or how I can fix it?

Chris
Title: Re: Who Voted What?
Post by: Søren Bjerg on January 25, 2007, 03:43:20 PM
I'm probably wrong, but the only reason I can think of right now - based on what I've read about similar behaviour with other modifications - is if the modification has not been completely uninstalled and certain parts of it was left in the source, causing duplicate entires on reinstallation of the modification.
Title: Re: Who Voted What?
Post by: lemur21 on January 25, 2007, 03:45:35 PM
That's very possible - but I'm way out of my element here in determining what to remove.

Could I attach the files here, and - maybe - you could take a quick look at them?

Chris
Title: Re: Who Voted What?
Post by: Glitch on January 25, 2007, 05:00:43 PM
Quote from: corruptor on September 13, 2006, 02:37:27 PM
www.theindelible.com/files/phperror.png

not sure why it faile on an else statement...

What that error message is telling you is that it's not expecting to find "else" - so that means that you have a problem with either your quotes, your curly braces, or the "if" itself
Title: Re: Who Voted What?
Post by: Søren Bjerg on January 26, 2007, 01:11:21 AM
Quote from: lemur21 on January 25, 2007, 03:45:35 PM
That's very possible - but I'm way out of my element here in determining what to remove.

Could I attach the files here, and - maybe - you could take a quick look at them?

Chris
Sure thing - I believe Display.template.php might be the incriminating file.
Title: Re: Who Voted What?
Post by: lemur21 on January 26, 2007, 08:47:06 AM
OK - here are the files...I'm attaching a handful, just to see if it could be one of these....

Thanks!

Chris
Title: Re: Who Voted What?
Post by: Søren Bjerg on January 26, 2007, 08:53:21 AM
In your Display.php file, the following block of code appears twice (and thus inserting the names of the voters into an array twice):


// Get information about the voters... [Who Voted What?]
    $request = db_query("
      SELECT
        lp.ID_CHOICE, lp.ID_MEMBER, m.realName
      FROM {$db_prefix}log_polls AS lp
        LEFT JOIN {$db_prefix}members AS m ON (m.ID_MEMBER = lp.ID_MEMBER)
      WHERE lp.ID_POLL = $topicinfo[ID_POLL]
      ORDER BY m.realName", __FILE__, __LINE__);
    while ($row = mysql_fetch_assoc($request)) {
      if(!isset($context['poll']['options'][$row['ID_CHOICE']]['voters']))
      {
        $context['poll']['options'][$row['ID_CHOICE']]['voters'] = array();
      }
      $voter = array(
        'ID_MEMBER' => $row['ID_MEMBER'],
        'realName' => $row['realName']
      );
      array_push($context['poll']['options'][$row['ID_CHOICE']]['voters'], $voter);
    }
    mysql_free_result($request);
}


If you remove one of them, it should work as intended.
Title: Re: Who Voted What?
Post by: lemur21 on January 26, 2007, 08:58:33 AM
Yep - that did it...I didn't really want to go tinkering around, but I started thinking, it probably had to be in the sources directory (since I DIDN'T replace that directory).

Thanks again!

Chris
Title: Re: Who Voted What?
Post by: puttputt on February 02, 2007, 09:41:29 PM
I installed 1.1.1, made a few style template changes to the Default theme, then proceeded to install this mod.  So far, it doesn't appear to be installing and displays 2 "Modification parse errors"

After cmoding every file's permission, still nothing. Oddly enough, I don't find a "Display.php" file either.

I would love to incorporate this feature 

Thanks

EDIT: Ok... I finally located my "Display.php" file!
Title: Re: Who Voted What?
Post by: MoreBloodWine on February 04, 2007, 11:31:20 PM
SMF 1.1.1  - TP 0.9.7

Same error both on the default theme and my custom theme... whats wrong and how can it be fixed...

8: Undefined index: whovotedwhatMode
File: /home/choiceo2/public_html/Themes/default/Display.template.php (main sub template - eval?)
Title: Re: Who Voted What?
Post by: growwl on February 13, 2007, 10:35:00 AM
hi søren!
could you provide the "alternative" who voted what mod for smf 1.1.2?
Title: Re: Who Voted What?
Post by: Squaregarden on February 15, 2007, 03:23:02 PM
Hi@ALL,

yeah that would be great! We just had a situation where we could have used it. So what can we do? Will u make us happy?  8)

LG Squaregarden
Title: Re: Who Voted What?
Post by: Søren Bjerg on February 16, 2007, 04:19:12 AM
I'll see if I can get around to bringing the version compatibility up to date later today.

Until then, try adding 1.1.2 to the "install for" list in the packages-info.xml file:

<install for="1.1.1, 1.1.2">
Title: Re: Who Voted What?
Post by: MoreBloodWine on February 16, 2007, 06:50:50 AM
**Looks down at the below quote... and thinks... well it did install ok and on the custom theme but wonders what the below error means... but also wonders why when he goes to a poll that the whole thing is messed up and one cant even view the poll or vote in it let alone view the voters who voted before the mod was installed**

Quote from: MoreBloodWine on February 04, 2007, 11:31:20 PM
SMF 1.1.1  - TP 0.9.7

Same error both on the default theme and my custom theme... whats wrong and how can it be fixed...

8: Undefined index: whovotedwhatMode
File: /home/choiceo2/public_html/Themes/default/Display.template.php (main sub template - eval?)

Title: Re: Who Voted What?
Post by: growwl on February 22, 2007, 11:02:23 AM
hi søren, any news on the alternative version?
Title: Re: Who Voted What?
Post by: Søren Bjerg on February 22, 2007, 11:51:01 AM
I've uploaded an updated package with native (un)installation support for 1.1.2 - should work.
Title: Re: Who Voted What?
Post by: MoreBloodWine on February 22, 2007, 01:15:42 PM
Hey Soren... have you had a chance to look at what I was trying to point out on the last page... its the same on the default theme so I know its nothing to do with the custom edits I made to my custom theme...
Title: Re: Who Voted What?
Post by: Søren Bjerg on February 22, 2007, 01:31:59 PM
I think the "Undefined index" error has to do with language strings not having been added to the language file. Should probably try reinstalling the modification... that's about all the ideas I have.
Title: Re: Who Voted What?
Post by: MoreBloodWine on February 22, 2007, 01:41:32 PM
Quote from: Søren Bjerg on February 22, 2007, 01:31:59 PM
I think the "Undefined index" error has to do with language strings not having been added to the language file. Should probably try reinstalling the modification... that's about all the ideas I have.
I've uninstalled / reinstalled a few times on both my production sites and my test site "default theme" ... results the same accross all three sites... so right now I'm kinda puzzled...  

Edit : Not sure if this will help but heres lines 48 - 56 of the file giving the error (Themes/default/Display.template.php)...


// Show each option with its corresponding percentage bar.
foreach ($context['poll']['options'] as $option)
{
The troublesome line number 51 --->        switch($modSettings['whovotedwhatMode']) {
          case 'select':
    echo '
    <tr>
    <td style="padding-right: 2ex;', $option['voted_this'] ? 'font-weight: bold;' : '', '">', $option['option'], '</td>', $context['allow_poll_view'] ? '
    <td nowrap="nowrap">' . $option['bar'] . ' ' . $option['votes'] . ' (' . $option['percent'] . '%)</td>' : '', '';
Title: Re: Who Voted What?
Post by: sgtschulze on February 22, 2007, 10:52:21 PM
I got it to work by selecting "Table View". I liked the drop down box better but oh well.  
Title: Re: Who Voted What?
Post by: Søren Bjerg on February 23, 2007, 01:25:28 AM
The drop-down box doesn't work anymore?
Title: Re: Who Voted What?
Post by: Me313 on February 23, 2007, 10:45:07 PM
hello.

i need help..hope u all dont mind..

am using helios_tp..and trying to make this mods work with the theme..but i dont know how to make it work anymore..what code should i put and where?display.php?but where? ..help?

thank you in advance..
a new user of smf...
Title: Re: Who Voted What?
Post by: J!ass on February 26, 2007, 08:44:15 AM
Hey guys,

I installed the mod on my upgraded SMF 1.1.2 and it works. But I've got the problem, that the last choice is beeing displayed two times, if voted.
It looks like this:
(https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fimg138.imageshack.us%2Fimg138%2F9103%2Ferrormd6.th.jpg&hash=1a2703ae5ded559692ce7187cf340774c98fd23b) (http://img138.imageshack.us/my.php?image=errormd6.jpg)


Thanks in advance
J!ass
Title: Re: Who Voted What?
Post by: WifiGamer on March 16, 2007, 06:33:19 AM
I hate to ask for a request in the mist of all of these issues. But.....

Is there any chance to add a permission on to this mod to only allow the owner of the poll (the creator) to view who voted what?

As it stands right now it looks like if I enable it on a membergroup then they can always see who voted what on any poll.  What I'd like is to only allow a person to view who voted if they are the ones who created the poll.  But also have the option to assign other member groups (like moderators) to always view who voted on any poll on the boards they are moderator's for?

I'm kinda new to SMF and can edit files OK but a little leery about creating a new permission from scratch.

BTW this is a great mod.  I love seeing who voted what and I love this mod because it satisfies my curiosity :P
Title: Re: Who Voted What?
Post by: traktorku on March 18, 2007, 03:38:58 PM
hi
i installed this mod but then i couldnt see the result of the polling
Title: Re: Who Voted What?
Post by: Vinspire on March 18, 2007, 09:10:24 PM
Quote from: traktorku on March 18, 2007, 03:38:58 PM
hi
i installed this mod but then i couldnt see the result of the polling

I had the same problem.
Title: Re: Who Voted What?
Post by: toma.baza on March 22, 2007, 09:41:29 AM
I recommend you to check if all updates (according to modification.xml) have happened. I change files manually and it started to work. Also you can try to change mod from "Select box" to "Table" if it will help.
Title: Re: Who Voted What?
Post by: Vinspire on March 25, 2007, 05:35:18 AM
Quote from: toma.baza on March 22, 2007, 09:41:29 AM
I recommend you to check if all updates (according to modification.xml) have happened. I change files manually and it started to work. Also you can try to change mod from "Select box" to "Table" if it will help.

I can view the result after i've changed the setting to "table"

anyway, any idea which file i should check for the manual installation to make sure the "select box" to work ?
Title: Re: Who Voted What?
Post by: edwardsiow on March 25, 2007, 06:10:54 AM
Quote from: traktorku on March 18, 2007, 03:38:58 PM
hi
i installed this mod but then i couldnt see the result of the polling


i also face the same problem....hmmm
Title: Re: Who Voted What?
Post by: edwardsiow on March 25, 2007, 06:35:09 AM
yes!!! table view and select box view can!!!

thanks for the creator of this mod....
Title: Re: Who Voted What?
Post by: weblady on March 25, 2007, 07:18:59 AM
I installed this mod... but had to change to "table view" to get it to work... no complaints here tho, I think this is a GREAT mod... fantastic to know WHO actually voted for what!  I've only been running my smf for a few months and was shocked that this function wasn't already a part of the forum... I LOVE this mod!  Thanks!
Title: Re: Who Voted What?
Post by: dDOTr2 on March 25, 2007, 12:18:07 PM
a great mod. thanks for making this.

it works great but i m flooded with this error message. kindly plz help me regrading this or can i ignore this error. thanks in advance. btw i m using Dilber MC theme.




http://localhost/indiamusics/index.php
8: Undefined index: whovotedwhatMode
File: C:\wamp\www\indiamusics\Themes\default\Display.template.php (main sub template - eval?)
Line: 59
Title: Re: Who Voted What?
Post by: BCB on April 06, 2007, 05:56:58 PM
Quote from: toma.baza on March 22, 2007, 09:41:29 AM
I recommend you to check if all updates (according to modification.xml) have happened. I change files manually and it started to work. Also you can try to change mod from "Select box" to "Table" if it will help.

Where would I do this? I have made sure that the changes have all taken effect in the files and it appears to have.

Any help on this would be great.

BTW this is what I am running on my site
Powered by SMF 1.1.2 | SMF © 2006-2007, Simple Machines LLC
TinyPortal v0.9.7 © Bloc
Title: Re: Who Voted What?
Post by: bassmadrigal on April 11, 2007, 04:03:30 PM
I installed the mod, and got this at the top of the screen :
// [Who Voted What?] $txt['poll_view_voters_expand_to_view'] = 'Expand to view:'; $txt['poll_view_voters_expanded_help1'] = 'Select a name to view'; $txt['poll_view_voters_expanded_help2'] = 'the member\'s profile...'; $txt['cannot_poll_view_voters'] = 'Sorry, you\'re not allowed to view which members voted for what option in the poll.'; $txt['permissionname_poll_view_voters'] = 'View voters'; $txt['permissionhelp_poll_view_voters'] = 'This permission allows people to see which members voted for what option in a poll.'; $txt['whovotedwhatMode'] = 'Who Voted What? mode'; $txt['whovotedwhatMode0'] = 'Select Box'; $txt['whovotedwhatMode1'] = 'Table View';

its on the very top of every page.   I am using the same theme as your site, I noticed.  I have checked the .php files listed in the mod.xml file, and everything appears to be good.
Title: Re: Who Voted What?
Post by: brotherlordacid on April 11, 2007, 04:33:16 PM
Exactly the same problem as the poster above me.
Latest Smf version, default theme. Help?  ;)
Title: Re: Who Voted What?
Post by: Kindred on April 11, 2007, 04:42:56 PM
the mod is apparently adding the text strings to modifications.english.php AFTER the closing ?>

go into modifications.english.php and move the ?> to the end of the file.
Title: Re: Who Voted What?
Post by: bassmadrigal on April 11, 2007, 05:01:49 PM
Duh, can't believe I missed that, the mod is still not working though, I'll double check that all of the files are not like that one.  Thank you for that.
Title: Re: Who Voted What?
Post by: kvanorsdel on April 18, 2007, 08:56:41 PM
Quote from: Vinspire on September 13, 2006, 01:49:22 PM
Quote from: corruptor on September 13, 2006, 01:08:26 PM
This is the single most frustrating fact about mods!
There needs to be a way simplify this by using a standard or keeping things consitant.
I tried to modify the files manually but got errors. I am not a programmer, and reading lines of code is not fun to me. (my problem, I know)
I am scared I will mess up a working site... (yes I make backups)
If anyone can help, I would love you forever for it. ( i know, you are all excited about that!  ::)  )

Quote from: usvi4me on September 13, 2006, 01:37:54 PM
For now this is my resolution as I really WANT this mod.

When I need to look at a poll and find out who voted what, I set the server mode in maintenance for a few minutes, change to the default theme and check the results.  Then ofcourse I have to remember to set it back to MY preferred theme and take it out of maintenance mode.

Maybe Soren will find us a fix ......

The thing is this is not Soren fault. He can't modified every single themes in SMF Board you know ?  :-\

Anyway, I've highlighted out what you guys need to do.

What you need to do to get it to work on other theme is modified Display.template.php and Modifications.english.php

P/S : Remember to make a backup copy of this file before you modified it :)

Display.template.php

Search for

![CDATA[ // Show each option with its corresponding percentage bar.
foreach ($context['poll']['options'] as $option)
echo '
<tr>
<td style="padding-right: 2ex;', $option['voted_this'] ? 'font-weight: bold;' : '', '">', $option['option'], '</td>', $context['allow_poll_view'] ? '
<td nowrap="nowrap">' . $option['bar'] . ' ' . $option['votes'] . ' (' . $option['percent'] . '%)</td>' : '', '
</tr>';


Replace that code with this

![CDATA[ // Show each option with its corresponding percentage bar.
foreach ($context['poll']['options'] as $option)
{
echo '
<tr>
<td style="padding-right: 2ex;', $option['voted_this'] ? 'font-weight: bold;' : '', '">', $option['option'], '</td>', $context['allow_poll_view'] ? '
<td nowrap="nowrap">' . $option['bar'] . ' ' . $option['votes'] . ' (' . $option['percent'] . '%)</td>' : '', '';
        // [Who Voted What?]
        if (allowedTo('poll_view_voters'))
        {
          echo '
  <td style="padding-left: 2ex;">
                    <select name="voters' . $option['ID_OPTION'] . '" id="jumpto" onchange="if (this.selectedIndex > 0 &amp;&amp; this.options[this.selectedIndex].value) window.location.href = smf_scripturl + this.options[this.selectedIndex].value.substr(smf_scripturl.indexOf(\'?\') == -1 || this.options[this.selectedIndex].value.substr(0, 1) != \'?\' ? 0 : 1);" style="width: 150px;">';
          if (!empty($context['poll']['options'][$option['ID_OPTION']]['voters']))
          {
            echo '
                      <option selected="selected" value="#">' . $txt['poll_view_voters_expand_to_view'] . '</option>
                      <option disabled="disabled" value="">----------------------</option>';
            foreach ($context['poll']['options'][$option['ID_OPTION']]['voters'] as $voter)
            {
              echo '
                      <option value="?action=profile;u=' . $voter['ID_MEMBER'] . '"> => ' . $voter['realName'] . '</option>';
            }
            echo '
                      <option disabled="disabled" value="">----------------------</option>
                      <option disabled="disabled" value="">' . $txt['poll_view_voters_expanded_help1'] . '</option>
                      <option disabled="disabled" value="">' . $txt['poll_view_voters_expanded_help2'] . '</option>';

          } else
          {
            echo '
                      <option disabled="disabled" selected="selected" value="">----------------------</option>';
          }
          echo '
                    </select>
                  </td>
          ';
        }
        echo '
</tr>';
}


Then go to your theme language folder look for Modifications.english.php file

Search

position="end"

Add this code before that code

![CDATA[// [Who Voted What?]
$txt['poll_view_voters_expand_to_view'] = 'Expand to view:';
$txt['poll_view_voters_expanded_help1'] = 'Select a name to view';
$txt['poll_view_voters_expanded_help2'] = 'the member\'s profile...';
$txt['cannot_poll_view_voters'] = 'Sorry, you\'re not allowed to view which members voted for what option in the poll.';
$txt['permissionname_poll_view_voters'] = 'View voters';
$txt['permissionhelp_poll_view_voters'] = 'This permission allows people to see which members voted for what option in a poll.';

I manually added the above codes in the Black22 TP theme and the drop down boxes in my polls appear but no names appear and I can not see any permissions to allow membergroups to view the View Voter That doesn't show up in the options.
Title: Re: Who Voted What?
Post by: bassmadrigal on April 18, 2007, 10:38:29 PM
Well today I went through and followed the modifications.xml file to the T. Initially I wasn't seeing any polls so I switched to the table mode. Now the polls show up but I still can't see who voted.

Here are my errors.

Undefined index: voted_this
Undefined index: option
Undefined index: bar
Undefined index: ID_OPTION
Undefined index: votes
Undefined index: percent

In the file
$Themedir/Display.template.php
Title: Re: Who Voted What?
Post by: kvanorsdel on April 18, 2007, 11:22:53 PM
SO how do I switch it to table mode to see if that works?
Title: Re: Who Voted What?
Post by: gtron on April 19, 2007, 04:56:26 PM
Quote from: BCB on April 06, 2007, 05:56:58 PM



Quote from: toma.baza on March 22, 2007, 09:41:29 AM
I recommend you to check if all updates (according to modification.xml) have happened. I change files manually and it started to work. Also you can try to change mod from "Select box" to "Table" if it will help.

Where would I do this? I have made sure that the changes have all taken effect in the files and it appears to have.

Any help on this would be great.

BTW this is what I am running on my site
Powered by SMF 1.1.2 | SMF © 2006-2007, Simple Machines LLC
TinyPortal v0.9.7 © Bloc

Admin> Features and Options> Basic Features> Who Voted What? mode (drop down box)


Quote from: bassmadrigal on April 11, 2007, 04:03:30 PM
I installed the mod, and got this at the top of the screen :
// [Who Voted What?] $txt['poll_view_voters_expand_to_view'] = 'Expand to view:'; $txt['poll_view_voters_expanded_help1'] = 'Select a name to view'; $txt['poll_view_voters_expanded_help2'] = 'the member\'s profile...'; $txt['cannot_poll_view_voters'] = 'Sorry, you\'re not allowed to view which members voted for what option in the poll.'; $txt['permissionname_poll_view_voters'] = 'View voters'; $txt['permissionhelp_poll_view_voters'] = 'This permission allows people to see which members voted for what option in a poll.'; $txt['whovotedwhatMode'] = 'Who Voted What? mode'; $txt['whovotedwhatMode0'] = 'Select Box'; $txt['whovotedwhatMode1'] = 'Table View';

its on the very top of every page.   I am using the same theme as your site, I noticed.  I have checked the .php files listed in the mod.xml file, and everything appears to be good.



if the code appares after %> in the following file move %> to the end of the file. if %> doesn't exsist at all... add it to the end of the following file....

Themes/default/languages/Modifications.english.php.


Quote from: kvanorsdel on April 18, 2007, 11:22:53 PM
SO how do I switch it to table mode to see if that works?


Admin> Features and Options> Basic Features> Who Voted What? mode (drop down box)
Title: Re: Who Voted What?
Post by: samames on April 19, 2007, 05:04:44 PM
this mod made my whole board shift to the left and made everything bigger, praise God it uninstalled well and went back to normall, i think it clashed with my shoutbox mod.
Title: Re: Who Voted What?
Post by: bassmadrigal on April 20, 2007, 07:29:09 AM
OK I went through all the code again and now see who voted. And it seems the errors I posted above were from a post before we converted the forum to smf, so that could be the problem.

Anyways the problem I am running into now has been mentioned previously in the thread. I am getting the results of the who voted on the poll twice. I dug through Display.template.php and have not found any duplicates.

I have created a temporary account for whoever to view this.
Account Name: temporary
Account Password: Aq36mdo8

Link to problem post: http://forums.xboxjunkies.org/index.php?topic=135.0

But all polls show up like this.

As far as I can tell it seems like it is this code that is the culprit

if(allowedTo('poll_view_voters'))
              {
                if(!empty($context['poll']['options'][$option['ID_OPTION']]['voters']))
                {
                  foreach($context['poll']['options'][$option['ID_OPTION']]['voters'] as $voter)
                  {
                    echo '<small><a href="?action=profile;u=' . $voter['ID_MEMBER'] . '">', $voter['realName'], '</a></small>&nbsp;';
                  }
                }
              }


It seems that the foreach that runs for some reason doubles the results.

I am at a loss, hopefully someone more knowledgeable can help me out. And it happens in both the classic theme and my modified Aa Damage. So the problem may not lie in the Display.template.php
Title: Re: Who Voted What?
Post by: Kindred on April 20, 2007, 08:21:10 AM
look in the database...  are the values stored twice?   Or maybe being read into the array twice?
Title: Re: Who Voted What?
Post by: bassmadrigal on April 21, 2007, 06:15:20 AM
No the values are not stored twice, and I don't know where to look to see the the values are being read into the array twice.

I guess it is time to go back to the modification.xml and see if possibly any duplicates were put in. I did double check all my theme files and those are fine, so I am assuming it is in another one.
Title: Re: Who Voted What?
Post by: Surfy on May 16, 2007, 08:16:20 PM
Very great Mod!!&nbsp; :o

The only thing i`m missing - is the Useroption to make Polls
- normal (secret) Votes
- public Votes (Who voted what)

This would be great!
Title: Re: Who Voted What?
Post by: Surfy on May 22, 2007, 03:44:50 PM
Quote from: Surfy on May 16, 2007, 08:16:20 PM
Very great Mod!!&nbsp; :o

The only thing i`m missing - is the Useroption to make Polls
- normal (secret) Votes
- public Votes (Who voted what)

This would be great!

I hope this addon is possible  ;)

Its a must have, that the Polls also could be anonymous  ;)
Title: Re: Who Voted What?
Post by: Hyronymus on May 23, 2007, 06:29:29 PM
Would it be possible to see the votes per membergroup? It can be interesting to compare how many people from Membergroup A and Membergroup Bvoted yes or no on a poll. Especially if one membergroup is more likely to be affected by the issue being polled.
Title: Re: Who Voted What?
Post by: Søren Bjerg on May 24, 2007, 04:48:27 AM
I'm pretty hung up with various other projects at the moment, so I won't be doing any further work on the modification any time soon.
Title: Re: Who Voted What?
Post by: Brad Jones on June 02, 2007, 09:04:57 AM
If anyone is having problems, after installing this mod, whereas their poll results no longer show up...
If you'd rather have the select box instead of the table view, perform the steps listed above, and then after you click "Save"...
Title: Re: Who Voted What?
Post by: MinasC on June 28, 2007, 08:26:58 PM
i get an error when trying to install to smf 1.1.3 ! isn't it compatible ?
Title: Re: Who Voted What?
Post by: Søren Bjerg on June 29, 2007, 07:10:50 AM
Apparently it isn't. However, I won't be able to update it any time soon due to the lack of a local development environment.
Title: Re: Who Voted What?
Post by: barath56 on June 29, 2007, 10:03:48 AM
cant it support 1.1.3
Title: Re: Who Voted What?
Post by: MinasC on June 29, 2007, 06:52:37 PM
Quote from: Søren Bjerg on June 29, 2007, 07:10:50 AM
Apparently it isn't. However, I won't be able to update it any time soon due to the lack of a local development environment.

too bad to hear , it's a really nice mod , used it before i upgrated !
Title: Re: Who Voted What?
Post by: RiderRaghav on June 29, 2007, 11:14:49 PM
When will you release a newer version for smf v1.1.3 ... ???
 
Thanks in advance ;)
Title: Re: Who Voted What?
Post by: Fustrate on June 30, 2007, 01:57:32 PM
I got it running easily in 1.1.3 ...

Just go into package-info.xml and put ,1.1.3 after 1.1.2 in the "install for" and "uninstall for" elements.

Then do the Display.template.php change by hand, it's only one thing.

Also remember to change to Table View as mentioned earlier.
Title: Re: Who Voted What?
Post by: RiderRaghav on June 30, 2007, 02:11:53 PM
Quote from: YodaOfDarkness on June 30, 2007, 01:57:32 PM
I got it running easily in 1.1.3 ...

Just go into package-info.xml and put ,1.1.3 after 1.1.2 in the "install for" and "uninstall for" elements.

Then do the Display.template.php change by hand, it's only one thing.

Also remember to change to Table View as mentioned earlier.

Can you please explain it in detail ??? coz  I'm new to all this... sry

Title: Re: Who Voted What?
Post by: Fustrate on June 30, 2007, 04:31:20 PM
Okay, download the 1_1_2 file to your desktop.

Using WinZip or another program, unzip the files to a folder. Go into that folder and right-click package-info.xml . Find the two places where it says
for="1.1.2" and replace them with for="1.1.2,1.1.3"

Using WinZip (or whatever you're using) again, select the package-info file and the modification file, and right-click them. Select "add to (name).zip"

You can then install this mod just like any other. Once it's installed, go to your Admin area and then to Features and Options (on the left). Near the top should be an option for "Who Voted What? mode" - change it to "Table View".

IF you're using a custom theme, open your Display.template.php under that theme's folder and find these lines:

<table border="0" cellpadding="0" cellspacing="0">';

// Show each option with its corresponding percentage bar.
foreach ($context['poll']['options'] as $option)
echo '
<tr>
<td style="padding-right: 2ex;', $option['voted_this'] ? 'font-weight: bold;' : '', '">', $option['option'], '</td>', $context['allow_poll_view'] ? '
<td nowrap="nowrap">' . $option['bar'] . ' ' . $option['votes'] . ' (' . $option['percent'] . '%)</td>' : '', '
</tr>';


change them to

<table border="0" cellpadding="5" cellspacing="0" style="border-collapse: collapse;">';

// Show each option with its corresponding percentage bar.
foreach ($context['poll']['options'] as $option)
{
        switch($modSettings['whovotedwhatMode']) {
          case 'select':
    echo '
    <tr>
    <td style="padding-right: 2ex;', $option['voted_this'] ? 'font-weight: bold;' : '', '">', $option['option'], '</td>', $context['allow_poll_view'] ? '
    <td nowrap="nowrap">' . $option['bar'] . ' ' . $option['votes'] . ' (' . $option['percent'] . '%)</td>' : '', '';
            // [Who Voted What?]
            if (allowedTo('poll_view_voters'))
            {
              echo '
      <td style="padding-left: 2ex;">
                        <select name="voters' . $option['ID_OPTION'] . '" id="jumpto" onchange="if (this.selectedIndex > 0 &amp;&amp; this.options[this.selectedIndex].value) window.location.href = smf_scripturl + this.options[this.selectedIndex].value.substr(smf_scripturl.indexOf(\'?\') == -1 || this.options[this.selectedIndex].value.substr(0, 1) != \'?\' ? 0 : 1);" style="width: 150px;">';
              if (!empty($context['poll']['options'][$option['ID_OPTION']]['voters']))
              {
                echo '
                          <option selected="selected" value="#">' . $txt['poll_view_voters_expand_to_view'] . '</option>
                          <option disabled="disabled" value="">----------------------</option>';
                foreach ($context['poll']['options'][$option['ID_OPTION']]['voters'] as $voter)
                {
                  echo '
                          <option value="?action=profile;u=' . $voter['ID_MEMBER'] . '"> => ' . $voter['realName'] . '</option>';
                }
                echo '
                          <option disabled="disabled" value="">----------------------</option>
                          <option disabled="disabled" value="">' . $txt['poll_view_voters_expanded_help1'] . '</option>
                          <option disabled="disabled" value="">' . $txt['poll_view_voters_expanded_help2'] . '</option>';
   
              } else
              {
                echo '
                          <option disabled="disabled" selected="selected" value="">----------------------</option>';
              }
              echo '
                        </select>
                      </td>
              ';
            }
            echo '
    </tr>';
            break;
          case 'table':
    echo '
    <tr>
    <td style="padding-right: 4ex; vertical-align: top;', $option['voted_this'] ? 'font-weight: bold;' : '', '">', $option['option'], '</td>';
            if($context['allow_poll_view']) {
              echo '
                    <td style="padding-right: 4ex;">
                      ', $option['bar'], '<br />';
              if(allowedTo('poll_view_voters'))
              {
                if(!empty($context['poll']['options'][$option['ID_OPTION']]['voters']))
                {
                  foreach($context['poll']['options'][$option['ID_OPTION']]['voters'] as $voter)
                  {
                    echo '<small><a href="?action=profile;u=' . $voter['ID_MEMBER'] . '">', $voter['realName'], '</a></small>&nbsp;';
                  }
                }
              }
              echo '
                    </td>
                    <td style="padding-left: 2ex; padding-right: 2ex; text-align: center; vertical-align: top;">', $option['votes'], '</td>
                    <td style="padding-left: 4ex; text-align: right; vertical-align: top;">', $option['percent'], '%</td>';
            }
            echo '
    </tr>';
            break;
        }
}


That should be it :) sorry if they're a bit hard to understand - I've never been good at giving detailed instructions :(
Title: Re: Who Voted What?
Post by: MinasC on July 01, 2007, 04:13:29 AM
Quote from: YodaOfDarkness on June 30, 2007, 01:57:32 PM
I got it running easily in 1.1.3 ...

Just go into package-info.xml and put ,1.1.3 after 1.1.2 in the "install for" and "uninstall for" elements.

Then do the Display.template.php change by hand, it's only one thing.

Also remember to change to Table View as mentioned earlier.

worked for me too , thnx a lot mate !
Title: Re: Who Voted What?
Post by: farknduckRC on July 05, 2007, 06:13:09 AM
Thanks for the info YodaofDarkness, mod worked perfect! (https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fwww.groundpoundersrc.com%2FSmileys%2Fdefault%2Fthumbsup.gif&hash=fdedb1e60d4e4c5eab1ad1dfe681e63483941af5)
Title: Re: Who Voted What?
Post by: Ninoslav on July 06, 2007, 02:15:14 PM
Yes, works flawlessly!
Title: Re: Who Voted What?
Post by: jasonhoblin on July 19, 2007, 02:20:09 AM
RE: user names list out without wrapping; user names nowrap

Didn't have time to see if this error was mentioned already, but since i took the time to fix it, i'd figured i should share.

The problem was the list of who voted for what was listing horizontally without wrapping. the table just pushed off to the right in a single row.

I am using the Dilber Multicolor theme. In the Display.template.php file in the default theme folder around line 101,

at the end of the echo, i edited the space from a coded space ...

echo '<small><a href="?action=profile;u=' . $voter['ID_MEMBER'] . '">', $voter['realName'], '</a></small>&nbsp';

...to an actual space...

echo '<small><a href="?action=profile;u=' . $voter['ID_MEMBER'] . '">', $voter['realName'], '</a></small> ';

... and now my list of voted users wraps. fyi.

^jasonhoblin
Title: Re: Who Voted What?
Post by: Rysiek on July 19, 2007, 02:47:33 AM
Quote from: YodaOfDarkness on June 30, 2007, 04:31:20 PM
Okay, download the 1_1_2 file to your desktop.

Using WinZip or another program, unzip the files to a folder. Go into that folder and right-click package-info.xml . Find the two places where it says
for="1.1.2" and replace them with for="1.1.2,1.1.3"

Using WinZip (or whatever you're using) again, select the package-info file and the modification file, and right-click them. Select "add to (name).zip"

You can then install this mod just like any other. Once it's installed, go to your Admin area and then to Features and Options (on the left). Near the top should be an option for "Who Voted What? mode" - change it to "Table View".
....

That should be it :) sorry if they're a bit hard to understand - I've never been good at giving detailed instructions :(

Okay, so I tried to install this package but no go. Then I was excited to see this thread and rushed off to do it. However, after making the change (which was only changing the for="1.1.2" stuff since I'm using the default theme), SMF tells me the package is not valid or corrupt. :/ Any ideas?

And yes, I'm using 1.1.3 and it's a fresh install.
Title: Re: Who Voted What?
Post by: jossanaijr on August 01, 2007, 03:59:31 PM
Quote from: YodaOfDarkness on June 30, 2007, 04:31:20 PM
Okay, download the 1_1_2 file to your desktop.

Using WinZip or another program, unzip the files to a folder. Go into that folder and right-click package-info.xml . Find the two places where it says
for="1.1.2" and replace them with for="1.1.2,1.1.3"

Using WinZip (or whatever you're using) again, select the package-info file and the modification file, and right-click them. Select "add to (name).zip"

You can then install this mod just like any other. Once it's installed, go to your Admin area and then to Features and Options (on the left). Near the top should be an option for "Who Voted What? mode" - change it to "Table View".

IF you're using a custom theme, open your Display.template.php under that theme's folder and find these lines:

<table border="0" cellpadding="0" cellspacing="0">';

// Show each option with its corresponding percentage bar.
foreach ($context['poll']['options'] as $option)
echo '
<tr>
<td style="padding-right: 2ex;', $option['voted_this'] ? 'font-weight: bold;' : '', '">', $option['option'], '</td>', $context['allow_poll_view'] ? '
<td nowrap="nowrap">' . $option['bar'] . ' ' . $option['votes'] . ' (' . $option['percent'] . '%)</td>' : '', '
</tr>';


change them to

<table border="0" cellpadding="5" cellspacing="0" style="border-collapse: collapse;">';

// Show each option with its corresponding percentage bar.
foreach ($context['poll']['options'] as $option)
{
        switch($modSettings['whovotedwhatMode']) {
          case 'select':
    echo '
    <tr>
    <td style="padding-right: 2ex;', $option['voted_this'] ? 'font-weight: bold;' : '', '">', $option['option'], '</td>', $context['allow_poll_view'] ? '
    <td nowrap="nowrap">' . $option['bar'] . ' ' . $option['votes'] . ' (' . $option['percent'] . '%)</td>' : '', '';
            // [Who Voted What?]
            if (allowedTo('poll_view_voters'))
            {
              echo '
      <td style="padding-left: 2ex;">
                        <select name="voters' . $option['ID_OPTION'] . '" id="jumpto" onchange="if (this.selectedIndex > 0 &amp;&amp; this.options[this.selectedIndex].value) window.location.href = smf_scripturl + this.options[this.selectedIndex].value.substr(smf_scripturl.indexOf(\'?\') == -1 || this.options[this.selectedIndex].value.substr(0, 1) != \'?\' ? 0 : 1);" style="width: 150px;">';
              if (!empty($context['poll']['options'][$option['ID_OPTION']]['voters']))
              {
                echo '
                          <option selected="selected" value="#">' . $txt['poll_view_voters_expand_to_view'] . '</option>
                          <option disabled="disabled" value="">----------------------</option>';
                foreach ($context['poll']['options'][$option['ID_OPTION']]['voters'] as $voter)
                {
                  echo '
                          <option value="?action=profile;u=' . $voter['ID_MEMBER'] . '"> => ' . $voter['realName'] . '</option>';
                }
                echo '
                          <option disabled="disabled" value="">----------------------</option>
                          <option disabled="disabled" value="">' . $txt['poll_view_voters_expanded_help1'] . '</option>
                          <option disabled="disabled" value="">' . $txt['poll_view_voters_expanded_help2'] . '</option>';
   
              } else
              {
                echo '
                          <option disabled="disabled" selected="selected" value="">----------------------</option>';
              }
              echo '
                        </select>
                      </td>
              ';
            }
            echo '
    </tr>';
            break;
          case 'table':
    echo '
    <tr>
    <td style="padding-right: 4ex; vertical-align: top;', $option['voted_this'] ? 'font-weight: bold;' : '', '">', $option['option'], '</td>';
            if($context['allow_poll_view']) {
              echo '
                    <td style="padding-right: 4ex;">
                      ', $option['bar'], '<br />';
              if(allowedTo('poll_view_voters'))
              {
                if(!empty($context['poll']['options'][$option['ID_OPTION']]['voters']))
                {
                  foreach($context['poll']['options'][$option['ID_OPTION']]['voters'] as $voter)
                  {
                    echo '<small><a href="?action=profile;u=' . $voter['ID_MEMBER'] . '">', $voter['realName'], '</a></small>&nbsp;';
                  }
                }
              }
              echo '
                    </td>
                    <td style="padding-left: 2ex; padding-right: 2ex; text-align: center; vertical-align: top;">', $option['votes'], '</td>
                    <td style="padding-left: 4ex; text-align: right; vertical-align: top;">', $option['percent'], '%</td>';
            }
            echo '
    </tr>';
            break;
        }
}


That should be it :) sorry if they're a bit hard to understand - I've never been good at giving detailed instructions :(

Well this is a detailed instrunction!
And worked perfectly.
SMF 1.1.3

Thank you!
Title: Re: Who Voted What?
Post by: Søren Bjerg on August 08, 2007, 10:15:44 AM
Within the end of the week I should have an updated version (a new version, really, as I'll be rewriting it) ready.

Sorry for the delay.
Title: Re: Who Voted What?
Post by: Søren Bjerg on August 08, 2007, 02:13:11 PM
WVW v1.1.3 for SMF v1.1.3 has been posted.

http://custom.simplemachines.org/mods/index.php?mod=347

Note: the modification comes disabled on install, please enable by choosing 'Select Box' or 'Table View' in Features and Options. Member groups must be given the 'View voters' permission to be able to make use of the modification as well.
Title: Re: Who Voted What?
Post by: en_shua on August 15, 2007, 08:13:01 AM
To upgrade my installation of this mod from 1.1.1 to 1.1.3 do I have to uninstall and then install the new one?
Title: Re: Who Voted What?
Post by: Søren Bjerg on August 15, 2007, 08:17:19 AM
Aye, no upgrade script is available.
Title: Re: Who Voted What?
Post by: en_shua on August 15, 2007, 09:10:59 AM
Thanks.  I edited the file to allow an uninstall for SMF 1.1.3, performed the uninstall, and then installed the new version.  Worked like a champ.  Thanks.
Title: Re: Who Voted What?
Post by: albescent on August 22, 2007, 05:46:07 PM
Søren, is there any way to tag Who Voted What with the Date/time they voted?
I use this mod to manage sign-ups for events and usually there is a limit to the number of people who I can allow to attend. if there are 10 spots available and 14 people vote yes i have no way to know who the first 10 people who signed up are. I'd rather not have to sit on the polls and lock voting based on my own reactions for lots of reasons one of many being that the (in the example) 4 extra people that signed up get to be on "on Call" status if one of the first 10 cant make it or doesnt show. Right now i'm requiring members to vote and reply which seems kind of redundant to me.
Title: Re: Who Voted What?
Post by: Søren Bjerg on August 23, 2007, 02:13:06 AM
Quote from: albescent on August 22, 2007, 05:46:07 PM
Søren, is there any way to tag Who Voted What with the Date/time they voted? [...]
It doesn't look like SMF stores the voting date/time in the database, so that functionality would have to be modified, but I'll see what I can do.

Alternatively, if you remove the ORDER BY m.realName from the SQL query in the WVW modification, I think it orders the results based on when they were added to the database.
Title: Re: Who Voted What?
Post by: MoreBloodWine on August 23, 2007, 02:24:46 AM
Hey soren im not a skilled coder by any means but couldnt you maybe set it up to grab the time from the forum or something and have it tagged that way... Like my forum is off set by two hours from my server so like if the forum time is displayed as lets say 2:43pm and someone votes at that time then the mod would see the forum displayed time as 2:43pm and tag the vote with that... So when someone clicks the dropdown they would now see the members name as expected and in that same dropdown they would see the time of the vote to the right of the voters name... Sorry if this sound weird but typing a message on a phone isnt easy heh... But hope you kinda get what im saying...
Title: Re: Who Voted What?
Post by: Søren Bjerg on August 23, 2007, 02:50:53 AM
No worries; I follow what you're saying, and adding a new field with the timestamp (server's time) of the vote is how I'd do it too.
Title: Re: Who Voted What?
Post by: MoreBloodWine on August 23, 2007, 02:58:10 AM
Cool but what i was getting at was having it "stamped" with the forums displayed time not the server time because not everyone has the same time as their server... Like literally right now i have 2:58am so my server would be 12:58am and the time stamp would preferably have to be the forums displayed time since like i said not everyone is on the same as their server... Hope this clears up what i actually meant a little...
Title: Re: Who Voted What?
Post by: albescent on August 23, 2007, 11:56:15 AM
Quote from: MoreBloodWine on August 23, 2007, 02:58:10 AM
Cool but what i was getting at was having it "stamped" with the forums displayed time not the server time because not everyone has the same time as their server... Like literally right now i have 2:58am so my server would be 12:58am and the time stamp would preferably have to be the forums displayed time since like i said not everyone is on the same as their server... Hope this clears up what i actually meant a little...
Thank you both for the prompt responses!
Actually having it stamped with server time would probably be best, that way we have an absolute  measure of Who Voted What, and When. FYI I'm using this for Signups for my World Of Warcraft Guild events, so we have members all over the world signing up. I'd hate to see someone on GMT lose out to someone on PST because of the -8 hour time difference.
I was also thinking that a field could be added to the smf_log_polls table that could store the Date/Time, but as I have very little php/sql experience I have no clue how to make the added field or make the vote button relay that information. I really do appreciate all the help.
Title: Re: Who Voted What?
Post by: MoreBloodWine on August 23, 2007, 12:35:19 PM
Well another thing to consider if at all possible could be to add an option somewhere in admin that lets the user decide wether or not to timestamp the "votes" with either server or forum time for those of us whos forums are offset from the server time...

Edit : BTW albescent... what server you on I'm on BWL for WoW...
Title: Re: Who Voted What?
Post by: albescent on August 23, 2007, 02:24:03 PM
Quote from: Søren Bjerg on August 23, 2007, 02:13:06 AM
Alternatively, if you remove the ORDER BY m.realName from the SQL query in the WVW modification, I think it orders the results based on when they were added to the database.
I'm sure this would work if i weren't such a dummy about php and sql commands, but  when i remove the ORDER BY m.realName I get this error:
Database Error
Please try again. If you come back to this error screen, report the error to an administrator.

@MoreBloodWine guild Ñemesis on Lightninghoof


ok, I'm just a retard, I got it working now. but it doesnt appear to reflect the actual order, and i'm not sure why.
Title: Re: Who Voted What?
Post by: Jason04R on September 06, 2007, 08:38:32 PM
Hi Guys,

How do i get it too look like this?

(https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fi33.photobucket.com%2Falbums%2Fd100%2FJnnw123%2Fdsdsd.jpg&hash=2d557e70802eed2cd47cbfc56c0a9526e5f49ef3)

Thanks
Title: Re: Who Voted What?
Post by: 2pac on September 06, 2007, 10:00:17 PM
Great mod thank you!
Title: Re: Who Voted What?
Post by: Søren Bjerg on September 07, 2007, 01:12:15 AM
Quote from: albescent on August 23, 2007, 02:24:03 PM
[...] ok, I'm just a retard, I got it working now. but it doesnt appear to reflect the actual order, and i'm not sure why.
Sorry for the delay, I'll see if I can find some time this weekend.

Quote from: Jason04R on September 06, 2007, 08:38:32 PM
Hi Guys,

How do i get it too look like this?

(https://www.simplemachines.org/community/proxy.php?request=http%3A%2F%2Fi33.photobucket.com%2Falbums%2Fd100%2FJnnw123%2Fdsdsd.jpg&hash=2d557e70802eed2cd47cbfc56c0a9526e5f49ef3)

Thanks
Errr... what has that screen shot got to do with polls and this modification?
Title: Re: Who Voted What?
Post by: albescent on September 07, 2007, 04:29:55 PM
Quote from: Søren Bjerg on September 07, 2007, 01:12:15 AM
Quote from: albescent on August 23, 2007, 02:24:03 PM
[...] ok, I'm just a retard, I got it working now. but it doesnt appear to reflect the actual order, and i'm not sure why.
Sorry for the delay, I'll see if I can find some time this weekend.

Søren,
  Thanks you are a god send. I appreciate the time you invest here helping those of us who dont know php from a hole in the ground.
Title: Re: Who Voted What?
Post by: mariolone on October 02, 2007, 08:39:16 AM
Does it works with SMF 1.1.4.? I tried to install it but the mod installer said me "Mod corrupted or not compatible with your version".

I am really interested in this mod and I would like to use it in SMF 1.1.4.: someone could help me?

Best regards and compliment for this really useful mod !
Title: Re: Who Voted What?
Post by: majestic13 on October 10, 2007, 02:43:03 PM
same problem here or is there a manuel install needed?

edit
modified the 1.1.3 - worked, thanks
Title: Re: Who Voted What?
Post by: jossanaijr on October 17, 2007, 08:27:12 AM
Can I choose which polls it will be enable and which polls it is not enabled?  If yes, how?  If not, can this be added in next release?
Thanks
Title: Re: Who Voted What?
Post by: RoccoGD on October 21, 2007, 07:29:26 AM
Quote from: majestic13 on October 10, 2007, 02:43:03 PM
same problem here or is there a manuel install needed?

edit
modified the 1.1.3 - worked, thanks

im very glad for you, that you finally made it working,
but it would be an unbeliveable task if you can help also others with the same problem.
can you upload the working mod for 1.1.4?
or a few words what we have to do, to make the mod with 1.1.4 work.
big thx
Title: Re: Who Voted What?
Post by: PNatal on October 21, 2007, 09:22:55 PM
Quote from: RoccoGD on October 21, 2007, 07:29:26 AM
(...)
can you upload the working mod for 1.1.4?
or a few words what we have to do, to make the mod with 1.1.4 work.
big thx


I'd like to see this mod working on 1.1.4 too...
If you can spare the time I would also apreciate it.

Thanx
Title: Re: Who Voted What?
Post by: Tesslys on October 22, 2007, 05:34:55 PM
I hope also there comes a update for 1.1.4.
Title: Re: Who Voted What?
Post by: RoccoGD on October 25, 2007, 09:31:44 PM
klick here for a way to get this mod version 1.1.3 to work with 1.1.4
http://www.simplemachines.org/community/index.php?topic=15259.0
akabugeyes  was very patienceful and guided me through the troubles.
Title: Re: Who Voted What?
Post by: Ming the Merciless on October 26, 2007, 09:30:39 AM
I uploaded the 1.1.3 package to the SMF Hacks Package Parser (http://www.smfhacks.com/packageparser/package.php), told it I had 1.1.3 (I'm on 1.1.4) and made the changes manually and it works fine for me so far.
Title: Re: Who Voted What?
Post by: JayP on October 26, 2007, 08:46:14 PM
Hi,

I have been struggling to get this mod working on just a newly installed board (v1.1.4), using the default template.

It seems that the mod is coded to search for the specific version number, which is warned against in supporting docs. I modified the v.1.1.3 mod by replacing any reference to 1.1.3 with 1.1.4, and the system was able to install it without it recognizing a problem. After installation, I checked the modified files and saw the necessary changes. However, even as the administrator, I don't see any boxes or pull-down menus that would show which users have voted for each polling option. In the control panel, I do see the option to allow "View Voters," but even if it's checked off, the voters don't show up.

I don't PHP so I was just hunting around the lines of code wondering if there were some variables changed in the upgrade from 1.1.3 to .4. I wanted to test it out on v.1.1.3 of the board, but all of the archived files I tried seem to be incomplete (only around 200k).

I think that this mod needs an update to work on 1.1.4. Either way, I could really use some assistance.

Thank you,
Jay
Title: Re: Who Voted What?
Post by: JayP on October 27, 2007, 12:10:08 AM
 :o  *Slaps forehead*

Silly me, it wasn't the code that was tripping me up, it was my lack of finding the field to select in the Control Panel to turn the view on to either Select Box or Table View. *ugh* Well, chalk that one up to user error.

Jay
Title: Re: Who Voted What?
Post by: mariolone on October 31, 2007, 06:08:15 PM
Quote from: majestic13 on October 10, 2007, 02:43:03 PM
same problem here or is there a manuel install needed?

edit
modified the 1.1.3 - worked, thanks
sorry?
Title: Re: Who Voted What?
Post by: mariolone on October 31, 2007, 06:19:27 PM
Quote from: mariolone on October 02, 2007, 08:39:16 AM
Does it works with SMF 1.1.4.? I tried to install it but the mod installer said me "Mod corrupted or not compatible with your version".

I am really interested in this mod and I would like to use it in SMF 1.1.4.: someone could help me?

Best regards and compliment for this really useful mod !

Someone could help me? Thank you!
Title: Re: Who Voted What?
Post by: mariolone on November 03, 2007, 10:45:19 AM
Quote from: mariolone on October 02, 2007, 08:39:16 AM
Does it works with SMF 1.1.4.? I tried to install it but the mod installer said me "Mod corrupted or not compatible with your version".

I am really interested in this mod and I would like to use it in SMF 1.1.4.: someone could help me?

Best regards and compliment for this really useful mod !

No replies?
Title: Re: Who Voted What?
Post by: jossanaijr on November 03, 2007, 10:54:35 AM
Did you trie to redownload the file?
Also you could try this as already explained in page 7:

Using WinZip or another program, unzip the files to a folder. Go into that folder and right-click package-info.xml . Find the two places where it says
for="1.1.2" and replace them with for="1.1.2,1.1.3,1.1.4"

Using WinZip (or whatever you're using) again, select the package-info file and the modification file, and right-click them. Select "add to (name).zip"

You can then install this mod just like any other. Once it's installed, go to your Admin area and then to Features and Options (on the left). Near the top should be an option for "Who Voted What? mode" - change it to "Table View".
Title: Re: Who Voted What?
Post by: mariolone on November 03, 2007, 12:33:58 PM
oh, reallly nice! Now it works,I attached the mod compatible with smf 1.1.4.

Thank you
Title: Re: Who Voted What?
Post by: jdvarner on November 29, 2007, 12:19:20 AM
mariolone, i used your version and i get display.template error. actually got that error with the original version as well. suspect another mod is interfering with this one. suggestions?
Title: Re: Who Voted What?
Post by: Kindred on November 29, 2007, 01:05:52 AM
I suggest that people be careful with mods attached to messages.   If it did not get verified through the SMF mod process, we have no idea what may be included in that package.... if it is good code or even if it works.

That being said, Mods conflicting is a definite possibility. It would help if we knew what mods you have installed.


Title: Re: Who Voted What?
Post by: Ol' Wombat on November 29, 2007, 01:57:52 AM
Actually it should not be allowed to post uncertified mods!

The mod scene already is like a walk in the jungle - you never know what happens to you next.
Title: Re: Who Voted What?
Post by: MothMan on December 04, 2007, 06:35:39 PM
I edited the package-info.xml to allow install/uninstall for 1.1.4, and the mod installs fine, and runs fine.

However, I later decided to uninstall the mod.

The uninstall check indicates everything passes.

However, when I actually select to go ahead with the uninstall, I get the following error:

----

Database Error
You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near 'IGNORE FROM smf_settings WHERE variable='whovotedwhatMode' LIMI
File: /home/content/o/t/h/othersi/html/Packages/temp/wvwDB.php
Line: 5

Note: It appears that your database may require an upgrade. Your forum's files are currently at version SMF 1.1.4, while your database is at version 1.10. The above error might possibly go away if you execute the latest version of upgrade.php.

----


I'm reluctant to try running the Upgrade script, as I'm afraid of losing all my mods... we've tweaked our forum substantially through mods, some of which had to be installed manually... so I'm reluctant to overwrite all that with the upgrade files.


Any chance someone can spot an error in the wvwDB.php file, which I could edit myself, in order to get it to run properly during the uninstall?

ie.  the error says there is a SQL syntax error in the file... can anyone find that error, and let me know how to correct it?
Title: Re: Who Voted What?
Post by: gameballa on December 04, 2007, 08:10:03 PM
thats because there is a for=uninstall as well that you need to change to 1.1.4 also..
Title: Re: Who Voted What?
Post by: Ol' Wombat on December 04, 2007, 08:10:09 PM
Feel the jungle?  :D

sorry could not resist
Title: Re: Who Voted What?
Post by: MothMan on December 05, 2007, 11:30:31 AM
Gameballa, thanks, but that's not the problem, I edited that portion of the package-info.xml.

The problem is with the wvwDB.php file, not the package-info.xml file.

Anyone else?
Title: Re: Who Voted What?
Post by: MothMan on December 11, 2007, 01:37:03 PM
Anyone?
Title: Re: Who Voted What?
Post by: MothMan on December 27, 2007, 12:36:54 AM
One more bumpity bump for the post Christmas crowd. :p

More info... I managed to update my database, but I still get the 'syntax' error as posted above... it no longer tells me that my database is out of date though, so the issue isn't my database.
Title: Re: Who Voted What?
Post by: souljaa on December 29, 2007, 06:43:29 PM
Is this safe to use for SMF 1.1.4?
Thanks
Souljaa
Title: Re: Who Voted What?
Post by: falguni1 on December 30, 2007, 06:26:35 AM
I want updated version.
Title: Re: Who Voted What?
Post by: CrazyHorse80 on January 01, 2008, 06:21:20 PM
This mod works great with SMF 1.1.4 (just installed): you only have to change version into installation file, then repack and upload... If you use a custom theme you'll have to manual edit your display.template.php.

Here is an Italian traslation for this mod:

Modifications.italian.php
// [Who Voted What?]
$txt['poll_view_voters_expand_to_view'] = 'Espandi:';
$txt['poll_view_voters_expanded_help1'] = 'Click per visualizzare';
$txt['poll_view_voters_expanded_help2'] = 'il profilo utente...';
$txt['cannot_poll_view_voters'] = 'Spiacente, non sei abilitato a vedere per quali opzioni del sondaggio gli utenti hanno votato.';
$txt['permissionname_poll_view_voters'] = 'Visualizza votanti';
$txt['permissionhelp_poll_view_voters'] = 'Questo permesso abilita a vedere per quali opzioni del sondaggio gli utenti hanno votato.';
$txt['whovotedwhatMode'] = 'Modalità chi ha votato cosa';
$txt['whovotedwhatMode0'] = 'Visualizza lista';
$txt['whovotedwhatMode1'] = 'Visualizza tabella';
$txt['whovotedwhatMode2'] = 'Disabilitato';


Thank for this useful mod!
Bye,
PS
Title: Re: Who Voted What?
Post by: falguni1 on January 02, 2008, 09:21:20 AM
ok.
Title: Re: Who Voted What?
Post by: hvusnme on January 02, 2008, 12:17:50 PM
Quote from: Kindred on November 29, 2007, 01:05:52 AM
I suggest that people be careful with mods attached to messages.   If it did not get verified through the SMF mod process, we have no idea what may be included in that package.... if it is good code or even if it works.

That being said, Mods conflicting is a definite possibility. It would help if we knew what mods you have installed.




So, do we know when there will be a 1.1.4 verified version of this??
Title: Re: Who Voted What?
Post by: Flippant on January 04, 2008, 11:56:17 AM
Really stuck with this one :(

Changed the package to say 1.1.4 and also default to utf8 in the modifications xml.

I can see permissions to add View voters in Admin > Permissions. But that's about it. Don't see any extra buttons/options on polls to display the voters.
Title: Re: Who Voted What?
Post by: PhilD on January 15, 2008, 12:21:27 PM
Has there been any progress on including a time stamp next to each user name who voted as discussed earlier in the postings? 

I could really use this feature. The project I am working on needs the date the person voted next to the name for proper documentation purposes.
Title: Re: Who Voted What?
Post by: slackerpunk on January 19, 2008, 07:45:48 AM
please reupload
Title: Re: Who Voted What?
Post by: slackerpunk on January 19, 2008, 10:11:54 PM
Quote from: CrazyHorse80 on January 01, 2008, 06:21:20 PM
This mod works great with SMF 1.1.4 (just installed): you only have to change version into installation file, then repack and upload... If you use a custom theme you'll have to manual edit your display.template.php.

Here is an Italian traslation for this mod:

Modifications.italian.php
// [Who Voted What?]
$txt['poll_view_voters_expand_to_view'] = 'Espandi:';
$txt['poll_view_voters_expanded_help1'] = 'Click per visualizzare';
$txt['poll_view_voters_expanded_help2'] = 'il profilo utente...';
$txt['cannot_poll_view_voters'] = 'Spiacente, non sei abilitato a vedere per quali opzioni del sondaggio gli utenti hanno votato.';
$txt['permissionname_poll_view_voters'] = 'Visualizza votanti';
$txt['permissionhelp_poll_view_voters'] = 'Questo permesso abilita a vedere per quali opzioni del sondaggio gli utenti hanno votato.';
$txt['whovotedwhatMode'] = 'Modalità chi ha votato cosa';
$txt['whovotedwhatMode0'] = 'Visualizza lista';
$txt['whovotedwhatMode1'] = 'Visualizza tabella';
$txt['whovotedwhatMode2'] = 'Disabilitato';


Thank for this useful mod!
Bye,
PS


anyway you could share your pack?
Title: Re: Who Voted What?
Post by: slackerpunk on January 23, 2008, 06:55:23 AM
nevermind got it to work with 1.1.4
Title: Re: Who Voted What?
Post by: remmons on January 28, 2008, 02:41:49 PM
Can you update the mod for SMV version 1.1.4?

I have SMF 1.1.4 installed, and the package manager will not install the mod which is says it is compatible with version 1.1.3.
Title: Re: Who Voted What?
Post by: remmons on January 28, 2008, 03:39:02 PM
After reading other posts here, I edited modification.xml and package-info.xml to change all instances of 1.1.3 to 1.1.4, and re-zipped them into who_voted_what_1-1-4.zip with wvwDB.php which needed no modification.  However, when I upload the package, I get the following error message:

The package you tried to upload either is not a valid package or has become corrupted.

Do you have any idea what might be wrong?

Title: Re: Who Voted What?
Post by: PhilD on January 29, 2008, 12:09:19 AM
All I did was change <install for="1.1.3"> to <install for="1.1.4"> and changed the line <uninstall for="1.1.3"> to <uninstall for="1.1.4"> in the file package-info.xml  I left the version alone in both package-info.xml and in modification.xml.

I then re-zipped all 3 files modification.xml, package-info.xml, and wvwDB.php. Then installed the package as usual.
Title: Re: Who Voted What?
Post by: remmons on January 29, 2008, 11:18:06 AM
Thanks for the info.

I think the problem may be an incompatibility between the file compressor which I am using (Winzip 11.1) and the compression used by SMF, rather than anything wrong with the content of the files.  I have not had time to complete troubleshooting it, but I may try using a different file compression utility.
Title: Re: Who Voted What?
Post by: PhilD on January 29, 2008, 11:41:41 AM
I use WinRAR for zips etc. Works good.
Title: Re: Who Voted What?
Post by: remmons on January 29, 2008, 05:48:21 PM
I basically got the mod working, but all the prompts are blank!  I am using the default themes with a freshly installed SMF v1.1.4.

When I go to "Admin / Feature and Options", there is a new selection box in the "Poll mode" section.  It has 3 choices, but their text is blank.  I tried selecting them anyhow, and found that the second showed a horizontal list of voters, and the third showed selection boxes of voters.  There is also no text next to the selection boxes.

When I go to "Admin/Permissions", there is a new check box in the "Poll" section, but no text to describe what the box does.  I guessed it allowed groups to see who voted what, so I checked it, and it did.

By the way, I had to zip the files with an old version of WinZip to get the package to upload without the "not a valid package / corrupted" message.  This must be an issue between WinZip and whatever SMF uses to unzip the package.

I'd feel a lot better about this mod if I could get the text to show.  How can I get the text to show properly?
Title: Re: Who Voted What?
Post by: pinoypetfinder on February 09, 2008, 06:17:25 PM
to those who have made this mod work on smf 1.1.4, can u please upload your zip and share it to us? would like to install this for our contest..
Title: Re: Who Voted What?
Post by: remmons on February 10, 2008, 01:18:34 PM
I would be happy to upload mine, but you have to be psychic to use it since all the prompts are blank.

What problems are you having?
Title: Re: Who Voted What?
Post by: Fustrate on February 10, 2008, 02:19:13 PM
remmons - are you using utf8? If so, try switching the forum language to plain English instead of English-utf8. Not sure if that's a problem with this mid, but its worth a shot
Title: Re: Who Voted What?
Post by: Kenny01 on February 12, 2008, 08:46:44 AM
It was working fine on my later version, but when i uninstalled it due to some other bugs, it never work again on my 1.1.4 version.
Title: Re: Who Voted What?
Post by: LiamTheDuck on February 12, 2008, 08:52:29 AM
can you update to 1.1.4?
Title: Re: Who Voted What?
Post by: Kenny01 on February 12, 2008, 08:59:57 AM
I do, still getting error message.
Title: Re: Who Voted What?
Post by: LiamTheDuck on February 12, 2008, 10:08:36 AM
mine just says its not compatible :(
Title: Re: Who Voted What?
Post by: Kenny01 on February 12, 2008, 11:20:16 AM
The mod is not that important to me, so i'm not bothering any more.
Title: Re: Who Voted What?
Post by: remmons on February 12, 2008, 11:33:38 AM
Thanks for your suggestion.  I tried it and it seems to have fixed some of the blanks.  Text seems to appear for users, but the administrative text is still blank.
Title: Re: Who Voted What?
Post by: remmons on February 12, 2008, 11:38:08 AM
Quote from: YodaOfDarkness on February 10, 2008, 02:19:13 PM
remmons - are you using utf8? If so, try switching the forum language to plain English instead of English-utf8. Not sure if that's a problem with this mid, but its worth a shot

Thanks for your suggestion.  I tried it and it seems to have fixed some of the blanks.  Text seems to appear for users, but the administrative text is still blank.
Title: Re: Who Voted What?
Post by: Dreambringer on February 14, 2008, 04:34:28 PM
I changed a few things.. not really sure if it will work for everyone, but it worked for me... 1.1.4

Title: Re: Who Voted What?
Post by: Trinny on March 04, 2008, 08:24:55 PM
Brilliant! Works perfectly on my 1.1.4, thank you Dreambringer for doing the work!
Title: Re: Who Voted What?
Post by: endiZ on March 22, 2008, 11:48:48 AM
Quote from: Dreambringer on February 14, 2008, 04:34:28 PM
I changed a few things.. not really sure if it will work for everyone, but it worked for me... 1.1.4



Thanks Dreambringer, it worked! Thanks.
Title: Re: Who Voted What?
Post by: Basie on March 22, 2008, 06:21:45 PM
This is a very useful mod. Will it be updated for 2.0?
Title: Re: Who Voted What?
Post by: look up on March 28, 2008, 12:24:44 PM
is there a way to get this mod to allow all members (not just the admin) to show who voted what?

maybe there could be an option to make your poll public when creating the poll?  but they may be better suited for a new mod request.
Title: Re: Who Voted What?
Post by: Basie on March 29, 2008, 03:34:32 AM
Quote from: look up on March 28, 2008, 12:24:44 PM
is there a way to get this mod to allow all members (not just the admin) to show who voted what?

There is an option in 'permissions' for this.


Title: Re: Who Voted What?
Post by: look up on March 29, 2008, 01:16:48 PM
Quote from: seek2501 on March 29, 2008, 03:34:32 AM
Quote from: look up on March 28, 2008, 12:24:44 PM
is there a way to get this mod to allow all members (not just the admin) to show who voted what?

There is an option in 'permissions' for this.



found it.  thanks.
Title: Re: Who Voted What?
Post by: Eliana Tamerin on April 03, 2008, 09:17:28 AM
Would it be possible for the mod setting in Features and Options to be turned on by default? Or at least make not that there is an option in settings? I've tried this mod before and didn't know about the settings option, and so I just thought it didn't work. Stupid on my part, probably, but I wasn't very good with coding at that time.

My theology is, if someone wants to install a mod, they want the functionality. Why have it disabled by default? This just confuses people. Enable one of the modes by default and tell users that there is an option in Features and Options to change it.
Title: Re: Who Voted What?
Post by: Paracelsus on April 11, 2008, 08:39:30 AM
Does anybody with PHP skills want to do a little debug? :P

Because the MOD gives me these errors:
8: Undefined index: percent
Ficheiro: /home/forumscp/public_html/Themes/smfone11rc3_green/Display.template.php (eval?)
Linha: 79
   
8: Undefined index: votes
Ficheiro: /home/forumscp/public_html/Themes/smfone11rc3_green/Display.template.php (eval?)
Linha: 79
   
8: Undefined index: bar
Ficheiro: /home/forumscp/public_html/Themes/smfone11rc3_green/Display.template.php (eval?)
Linha: 79

8: Undefined index: option
Ficheiro: /home/forumscp/public_html/Themes/smfone11rc3_green/Display.template.php (eval?)
Linha: 78
   
8: Undefined index: voted_this
Ficheiro: /home/forumscp/public_html/Themes/smfone11rc3_green/Display.template.php (eval?)
Linha: 78
   
8: Undefined index: percent
Ficheiro: /home/forumscp/public_html/Themes/smfone11rc3_green/Display.template.php (eval?)
Linha: 79

and line 79 corresponds to:
            foreach ($context['poll']['options'] as $option)
            {
        if (!allowedTo('poll_view_voters') || $modSettings['whovotedwhatMode'] == 'disabled')
        {
                  echo '
                            <tr>
                                <td style="padding-right: 2ex;', $option['voted_this'] ? 'font-weight: bold;' : '', '">', $option['option'], '</td>', $context['allow_poll_view'] ? '
                                <td nowrap="nowrap">' . $option['bar'] . ' ' . $option['votes'] . ' (' . $option['percent'] . '%)</td>' : '', '


While the original code isn't much different:
            foreach ($context['poll']['options'] as $option)
                echo '
                            <tr>
                                <td style="padding-right: 2ex;', $option['voted_this'] ? 'font-weight: bold;' : '', '">', $option['option'], '</td>', $context['allow_poll_view'] ? '
                                <td nowrap="nowrap">' . $option['bar'] . ' ' . $option['votes'] . ' (' . $option['percent'] . '%)</td>' : '', '
Title: Re: Who Voted What?
Post by: efil59 on April 13, 2008, 12:23:02 AM
Quote from: Dreambringer on February 14, 2008, 04:34:28 PM
I changed a few things.. not really sure if it will work for everyone, but it worked for me... 1.1.4



Hi,
I was testing the mod (1.1.4), and i got Error in Package Installation with 2 files:
Themes/default/Display.template.php
Sources/ModSettings.php

Can you say how to insert the code manually for those 2 files?
Title: Re: Who Voted What?
Post by: 2pac on April 19, 2008, 09:34:22 AM
for some reason, the names are appearing twice on my board... anybody know why that might be?

http://ninerskickass.com/forum/index.php/topic,543.0.html
Title: Re: Who Voted What?
Post by: 2pac on April 22, 2008, 12:17:46 AM
anybody? ???
Title: Re: Who Voted What?
Post by: jossanaijr on April 22, 2008, 12:22:33 AM
Quote from: 2pac on April 19, 2008, 09:34:22 AM
for some reason, the names are appearing twice on my board... anybody know why that might be?

http://ninerskickass.com/forum/index.php/topic,543.0.html
It seems to me that you can have script duplicity in some php file used by this MOD.
Title: Re: Who Voted What?
Post by: Marcus Forsberg on April 22, 2008, 12:31:27 AM
How will this look when used?
I don't understand the picture in the first message
(http://www.sorenbjerg.dk/images/smf_mod_whovotedwhat.jpg)
Title: Re: Who Voted What?
Post by: 2pac on April 22, 2008, 04:22:58 AM
Quote from: jossanaijr on April 22, 2008, 12:22:33 AM
Quote from: 2pac on April 19, 2008, 09:34:22 AM
for some reason, the names are appearing twice on my board... anybody know why that might be?

http://ninerskickass.com/forum/index.php/topic,543.0.html
It seems to me that you can have script duplicity in some php file used by this MOD.

you were right... i installed this a while back but for some reason i uninstalled it. it must have not uninstalled properly because the code that's supposed to be inserted was there twice.

thanks for the tip!
Title: Re: Who Voted What?
Post by: 2pac on April 22, 2008, 04:29:07 AM
Quote from: MTF95 on April 22, 2008, 12:31:27 AM
How will this look when used?
I don't understand the picture in the first message
(http://www.sorenbjerg.dk/images/smf_mod_whovotedwhat.jpg)

basically it shows you the names of the two voters who chose the option on the left (which is blurred out)

there are two ways that it lets you display the voter names, one of them is like that picture, the other one is like this example here

http://ninerskickass.com/forum/index.php/topic,178.0.html
Title: Re: Who Voted What?
Post by: Darkness_ on April 27, 2008, 09:36:32 AM
can't there be made a 1.1.4 version
Title: Re: Who Voted What?
Post by: Basie on April 27, 2008, 09:45:59 AM
I'm using this on 1.1.4 and it works fine.


I'd like to see it updated for 2.0 though...
Title: Re: Who Voted What?
Post by: Darkness_ on April 27, 2008, 09:51:04 AM
how did you installed it?
manually?
Title: Re: Who Voted What?
Post by: Basie on April 27, 2008, 10:07:50 AM
Quote from: Darkness_ on April 27, 2008, 09:51:04 AM
how did you installed it?
manually?

No, I've never needed to install a mod manually.

Try this... (see attached file)

Title: Re: Who Voted What?
Post by: Darkness_ on April 27, 2008, 10:21:54 AM
thanks :)
Title: Re: Who Voted What?
Post by: Marcus Forsberg on April 28, 2008, 12:37:14 AM
How will this look when used?
I don't understand the picture in the first message
(http://www.sorenbjerg.dk/images/smf_mod_whovotedwhat.jpg)
Title: Re: Who Voted What?
Post by: PhilD on May 05, 2008, 12:24:54 AM
Has anyone gotten Who Voted What to install on SMF 1.1.5?  I keep getting "The package you are trying to download or install is either corrupt or not compatible with this version of SMF."

I made the mods to the files; same as when I installed it on 1.1.4 of SMF. I like this mod and would like to see it work on later versions of the forum.
Title: Re: Who Voted What?
Post by: PhilD on May 05, 2008, 10:26:22 PM
Duh!  Stupid me, I forgot the server does not like zip files. Changed the mod to tar.gz and things went fine today.
Title: Re: Who Voted What?
Post by: Marcus Forsberg on May 06, 2008, 01:51:55 AM
ONCE AGAIN I ASK:
How will this look when used?
I don't understand the picture in the first message
(http://www.sorenbjerg.dk/images/smf_mod_whovotedwhat.jpg)
Title: Re: Who Voted What?
Post by: Eliana Tamerin on May 06, 2008, 06:54:55 AM
Install it on a test forum, enable it under Features and Options (Basic settings), and try out a poll. Vote in it. Then see what it looks like.
Title: Re: Who Voted What?
Post by: Marcus Forsberg on May 06, 2008, 07:00:05 AM
Don't have any forum right now.
Title: Re: Who Voted What?
Post by: Eliana Tamerin on May 06, 2008, 07:02:46 AM
Download wamp or xampp or another localhost server and install it on your own computer.
Title: Re: Who Voted What?
Post by: MadTurki on May 14, 2008, 09:39:09 PM
I'm using the 1.1.4 installer Seek2501 posted above.  It gave me a test failed error on my /Themes/default/Display.template.php (which I ignored :P).  I dont have any "problems" occuring but I cannot see the names of those who voted.  I did edit the settings for the group I'm in and gave myself the appropriate permissions.
Title: Re: Who Voted What?
Post by: Kindred on May 16, 2008, 12:39:51 PM
well, if the test failed, doesn't that tell you exactly what the problem is?

The test failed, and so the installed was no able to automatically install the mod in that file...  Since that file control the display of those who voted..............

you will have to manually apply the changes to your display.template.php
Title: Re: Who Voted What?
Post by: Drucila on May 20, 2008, 03:04:04 PM
So I picked enable polls, picked select box, wouldnt show, picked table view, wouldnt show, made a new poll wouldnt show, I am on an admin account and I dont see anything different. relogged in, wouldnt show...out of ideas here.

The mod installed, uninstalled, reinstalled fine.

I am running smf 1.1.4...

Anyone have any ideas why its not showing me the results? Wrote to display.php fine.

thanks
dru
Title: Re: Who Voted What?
Post by: rokit on May 23, 2008, 03:42:30 AM
Quote from: Eliana Tamerin on May 06, 2008, 06:54:55 AM
Install it on a test forum, enable it under Features and Options (Basic settings), and try out a poll. Vote in it. Then see what it looks like.
I was able to upload successfully on my forums however when trying to check the settings under "Features and Options," it does not show but it shows something is suppose to go there but it's tangled. 
Title: Re: Who Voted What?
Post by: MadTurki on May 26, 2008, 04:07:19 PM
Quote from: Kindred on May 16, 2008, 12:39:51 PM
well, if the test failed, doesn't that tell you exactly what the problem is?

The test failed, and so the installed was no able to automatically install the mod in that file...  Since that file control the display of those who voted..............

you will have to manually apply the changes to your display.template.php

I went through the xml file and all changes happened except for that 1 doc.  I made the changes there in my custom theme and still nothing.  I edited the file in default theme, and still nothing.  Any suggestions?
Title: Re: Who Voted What?
Post by: Nathaniel on June 03, 2008, 06:05:04 AM
Okay, from what I can see the last post in this thread from the Modder was in August 2007, Is there any chance that this Mod will be updated to SMF 2 Beta 3.1 or has it been abandoned? If so then I might consider making a version for SMF 2 Beta, just for fun! :)
Title: Re: Who Voted What?
Post by: Søren Bjerg on June 06, 2008, 06:36:13 AM
My apologies for being a "no show" in here and to those having had problems getting the modification to work in the many new versions of SMF released since the last update.

I'll try to get a development environment up and running on my machine in near future and get the modification updated to the new version(s?).
Title: Re: Who Voted What?
Post by: Nathaniel on June 06, 2008, 06:53:38 AM
Quote from: Søren Bjerg on June 06, 2008, 06:36:13 AM
My apologies for being a "no show" in here and to those having had problems getting the modification to work in the many new versions of SMF released since the last update.

I'll try to get a development environment up and running on my machine in near future and get the modification updated to the new version(s?).

Okay, that would be really good!  :D

Sorry for not thinking that you exsisted!  ;D

Below is a thread relating to the question of this mod for SMF 2 Beta, I was thinking of making a new similar mod for SMF 2 Beta, but it makes a lot more sense for you to update it!

http://www.simplemachines.org/community/index.php?topic=237762.0

Thanks again, now I can think about the other mods which I want to create.  :)
Title: Re: Who Voted What?
Post by: gioxxxx on June 11, 2008, 03:53:22 PM
Hi
I dont know if it's ok to modify and post others mods and I dont know how to upload it on Mods page on SMF site, but anyway I'm going to post this mod here for SMF 1.1.5
I did little changes and it works on my SMF 1.1.5
Title: Re: Who Voted What?
Post by: Noanme on June 11, 2008, 04:06:33 PM
Quote from: gioxxxx on June 11, 2008, 03:53:22 PM
Hi
I dont know if it's ok to modify and post others mods but anyway I'm going to post this mod for SMF 1.1.5
I did little changes and it works on my SMF 1.1.5

YOU ARE THE GOD!  O:) O:)
Title: Re: Who Voted What?
Post by: lwood79 on June 12, 2008, 04:31:16 PM
Awesome!  Thank you!  :D
Title: Re: Who Voted What?
Post by: gioxxxx on June 13, 2008, 10:49:03 AM
anyone knows how to upload file on Mods Download?
Title: Re: Who Voted What?
Post by: THE BRA1N on June 15, 2008, 07:02:44 AM
We need this for 2.0!
Title: Re: Who Voted What?
Post by: Nathaniel on June 15, 2008, 07:09:37 AM
Quote from: gioxxxx on June 13, 2008, 10:49:03 AM
anyone knows how to upload file on Mods Download?

You can't unless you submit a new mod, which would be pointless. Maybe you should wait until the modder actually updates this mod? He/She may even use your code to complete the update.

Quote from: THE BRA1N on June 15, 2008, 07:02:44 AM
We need this for 2.0!

I agree, but maybe you should have a read of the thread, earlier the modder says that they will update this mod when they get some time.
Title: Re: Who Voted What?
Post by: THE BRA1N on June 16, 2008, 05:24:26 PM
Quote from: LHVWB on June 15, 2008, 07:09:37 AM

Quote from: THE BRA1N on June 15, 2008, 07:02:44 AM
We need this for 2.0!

I agree, but maybe you should have a read of the thread, earlier the modder says that they will update this mod when they get some time.

I did read it and was expressing my support for an update.  ;)
Title: Re: Who Voted What?
Post by: Gandalf123 on June 21, 2008, 05:40:22 PM
I've converted this mod to work with smf 2.0 beta 3 and 3.1

I did this because we wanted it on our site. I will enclose the package in this post. Remember that this is for smf 2.0 beta 3 or 3.1 ONLY.

The author of this mod can use any or all of my code included in this post to be included in the official release.

This is a straight convert from present mod to work with smf 2.0 beta versions. I've not added nor removed any functions from the mod.
Title: Re: Who Voted What?
Post by: PhilD on June 21, 2008, 08:07:53 PM
Can you gandalf_the_swede (or someone else)  add a date/time stamp of when a person voted into additional fields ( one field for date and one field for time or just one for both is ok) in the database table for this mod?  Report generation (View Report) of the voting results with the time/date stamps included would be nice addition also.

I and trying to set up something for a club to use for voting and need the date/time stamp recorded as to when a person voted on a poll. Who voted what in a poll is a great idea and I use this mod on all my sites.

Conception would be:

Name, vote cast, date cast, time cast

All this information does not have to be listed on the poll results, but needs to be recorded in the database table. Display could be from a button that says View/Print Report. This would create a report with the option to print the report with the poll question, poll open date/time, poll close date/time, and who created the poll. Under this info a persons name, vote cast, date cast, time cast could be listed for each option in the poll.


This would make record keeping much more accurate and provide a paper trail for record keeping.

I think most of this information is available but I do not have enough programming experience to pull and assemble the data into anything meaningful and would hope someone will help out.
Title: Re: Who Voted What?
Post by: Matthew Schenker on June 25, 2008, 01:31:18 PM
Quote from: gioxxxx on June 11, 2008, 03:53:22 PM
Hi
I dont know if it's ok to modify and post others mods and I dont know how to upload it on Mods page on SMF site, but anyway I'm going to post this mod here for SMF 1.1.5
I did little changes and it works on my SMF 1.1.5

Hi, I definitely want this modification on my site.  What changes are necessary to make it work with 1.1.5?
Thanks,
Matt
Title: Re: Who Voted What?
Post by: gioxxxx on June 26, 2008, 09:14:48 AM
Quote from: Matthew Schenker on June 25, 2008, 01:31:18 PM
Quote from: gioxxxx on June 11, 2008, 03:53:22 PM
Hi
I dont know if it's ok to modify and post others mods and I dont know how to upload it on Mods page on SMF site, but anyway I'm going to post this mod here for SMF 1.1.5
I did little changes and it works on my SMF 1.1.5

Hi, I definitely want this modification on my site.  What changes are necessary to make it work with 1.1.5?
Thanks,
Matt
u dont need to do any changes I did necessary changes to mod. u just download than upload and install with SMF mod install function.

http://www.simplemachines.org/community/index.php?action=dlattach;topic=110220.0;attach=58368
Title: Re: Who Voted What?
Post by: Matthew Schenker on June 26, 2008, 09:31:56 AM
gioxxxx,
Thank you for explaining that!
Matthew
Title: Re: Who Voted What?
Post by: gioxxxx on June 26, 2008, 09:51:02 AM
Quote from: Matthew Schenker on June 26, 2008, 09:31:56 AM
gioxxxx,
Thank you for explaining that!
Matthew
no problem
Title: Re: Who Voted What?
Post by: jossanaijr on June 26, 2008, 02:01:32 PM
Is it possible to choose which polls I want it enable or not?
Title: Re: Who Voted What?
Post by: jossanaijr on July 02, 2008, 11:57:51 AM
Quote from: jossanaijr on June 26, 2008, 02:01:32 PM
Is it possible to choose which polls I want it enable or not?
bumping...
Title: Re: Who Voted What?
Post by: jossanaijr on July 09, 2008, 10:56:34 AM
No?
Title: Re: Who Voted What?
Post by: Eliana Tamerin on July 09, 2008, 11:03:13 AM
No, that's not a feature of this mod.
Title: Re: Who Voted What?
Post by: jossanaijr on July 09, 2008, 04:59:24 PM
Quote from: Eliana Tamerin on July 09, 2008, 11:03:13 AM
No, that's not a feature of this mod.
Yes, I know but it would be nice to have this option.
Or a code to modify it?
Title: Re: Who Voted What?
Post by: THE BRA1N on July 20, 2008, 01:15:52 AM
Quote from: Gandalf123 on June 21, 2008, 05:40:22 PM
I've converted this mod to work with smf 2.0 beta 3 and 3.1

I did this because we wanted it on our site. I will enclose the package in this post. Remember that this is for smf 2.0 beta 3 or 3.1 ONLY.

The author of this mod can use any or all of my code included in this post to be included in the official release.

This is a straight convert from present mod to work with smf 2.0 beta versions. I've not added nor removed any functions from the mod.

Thank you for sharing that. I will try it out.
Title: Re: Who Voted What?
Post by: 4b11l on July 20, 2008, 02:10:29 AM
Any ideas if this will work with 1.1.5?
Title: Re: Who Voted What?
Post by: CrazyHorse80 on July 20, 2008, 04:03:22 AM
Quote from: 4b11l on July 20, 2008, 02:10:29 AM
Any ideas if this will work with 1.1.5?

It works!
Bye,
PS
Title: Re: Who Voted What?
Post by: Fonk on October 03, 2008, 02:59:36 PM
Hallo, ich versuche seit einiger Zeit das Who Voted What Plugin zu installieren...
Ich habe die Berechtigung in der Gruppe aktiviert, und unter Forum Einstellungen auf Table eingestellt. In den Umfragen erscheinen aber keine Namen
Title: Re: Who Voted What?
Post by: Apllicmz on October 11, 2008, 12:13:53 PM
YES SHE WORK FINE
IAM UPDATE PORTUGUESE LINGUAGE AND SUPPORT 1.1.6
Title: Re: Who Voted What?
Post by: Nightwish_76 on October 16, 2008, 07:01:15 AM
Hallo,
I have SMF 1.1.6.
I have tried all posted version an none of it did work.
I can't see any button "who voted what". (See Screenshot)
Can somebody give me a hint?

Greetz,
Nob
Title: Re: Who Voted What?
Post by: Sakae on October 16, 2008, 10:41:44 AM
Quote from: Nightwish_76 on October 16, 2008, 07:01:15 AM
Hallo,
I have SMF 1.1.6.
I have tried all posted version an none of it did work.
I can't see any button "who voted what". (See Screenshot)
Can somebody give me a hint?

It worked fine to me.

I repacked the mod to work with all versions (including brazilian utf8 language).

***** Don't forget to enable this mod on Features and Options ("Who Voted What? mode" box of options). *******

Title: Re: Who Voted What?
Post by: mforest on October 17, 2008, 07:43:00 PM
Quote from: Nightwish_76 on October 16, 2008, 07:01:15 AM
***** Don't forget to enable this mod on Features and Options ("Who Voted What? mode" box of options). *******

I have tried both version, the one for 1.1.6 and the MOD version. I have tried both the table view and select box and none of them seem to work. I have tried it as both Administrator and a normal user and nothing. What could I have missed?
Title: Re: Who Voted What?
Post by: mforest on October 17, 2008, 09:23:03 PM
<G> Theme. When I changed from Diablo to the default theme, it works!
I "vote" for this to be a standard feature!
Well done.
/Martin
Title: Re: Who Voted What?
Post by: Sakae on October 23, 2008, 05:07:45 PM
Quote from: mforest on October 17, 2008, 09:23:03 PM
<G> Theme. When I changed from Diablo to the default theme, it works!

You have to edit your theme's templates to make it work on <G> Theme :)
Title: Re: Who Voted What?
Post by: gtron on October 30, 2008, 01:36:28 PM
any plans to update this for 1.1.6 or any alternative mod suggestions to replace it? :D
Title: Re: Who Voted What?
Post by: Jessikard on November 10, 2008, 07:22:17 AM
i´ve installed this mod in my smf 1.1.7 and it works well

opened the package.xml and expand the version up to - 1.1.99
uploaded the package include the error in the display
then opened display.template.php via ftp and changed manually the parsed part

don´t forget the modification.*language*.php if you use others than engl.

activate in ACP Setting/Options - ready
Title: Re: Who Voted What?
Post by: Sakae on November 10, 2008, 10:22:44 AM
Working great in my SMF 1.1.7 too.
Title: Re: Who Voted What?
Post by: Ryanna on December 09, 2008, 10:20:27 AM
Anyone knows if it works for 2.0 Beta 4?
Title: Re: Who Voted What?
Post by: AHA_Web on December 12, 2008, 01:34:42 PM
Does anyone know of a way to Modify this to display who has voted but not for what option. We want to use this as a way to track down people who have not voted and contact them but not see who they have voted for.

Thank You.
Title: Re: Who Voted What?
Post by: anand on January 20, 2009, 09:21:39 AM
Nobody seems to have a problem installing this...

I have downloaded the zip and tried to upload it under the packages section of the admin panel. When I upload the zip there it says that's it's an invalid or corrupt file I'm trying to upload. When I try to upload just the XML it says it won't accept XML.

Now I've uploaded the contents of the zip file to the packages folder on my webserver and it's being recognized only I can't install it. My only options are "list files" and "delete". How am I supposed to get this working?

A readme with just 4 or 5 steps contained in the zip would've been nice :)
Title: Re: Who Voted What?
Post by: remmons on January 20, 2009, 10:50:03 AM
I also had problems with SMF complaining that my package file was corrupt.  In my case, I think it was caused by loading the package zip file into Winzip, and re-saving it.  I think there may be some incompatibility in format between a Winzip and SMF zip file.  I forget exactly how I solved the problem.  Either I used a zip program other than Winzip, or I got downloaded a fresh copy of the package, and did not open or save it with Winzip.

Let us know how you make out, since I was not sure exactly what was wrong in my case.
Title: Re: Who Voted What?
Post by: anand on January 20, 2009, 11:41:18 AM
Quote from: remmons on January 20, 2009, 10:50:03 AM
I also had problems with SMF complaining that my package file was corrupt.  In my case, I think it was caused by loading the package zip file into Winzip, and re-saving it.  I think there may be some incompatibility in format between a Winzip and SMF zip file.  I forget exactly how I solved the problem.  Either I used a zip program other than Winzip, or I got downloaded a fresh copy of the package, and did not open or save it with Winzip.

Let us know how you make out, since I was not sure exactly what was wrong in my case.

Thanks for the info.

Well I made some progress. I deciced to drop the entire zip thing all together and I upload a folder inside the SMF default packages folder on the server. I already did this earlier and the package did get listed but I couldn't do anything with it. Now that I've changed the file permissions via chmod I can apply it but now we're onto the next error.

QuoteInstalling this package will perform the following actions:
   Type    Action    Description
1.    Execute Code    wvwDB.php   
2.    Execute Modification    modification.xml    Modification parse error
3.    Execute Modification    -    Modification parse error

I get bells and whistles everywhere saying I shouldn't do it or at least make a backup...
Title: Re: Who Voted What?
Post by: X3mE on January 20, 2009, 12:18:52 PM
Quote from: remmons on January 20, 2009, 10:50:03 AM
I also had problems with SMF complaining that my package file was corrupt.  In my case, I think it was caused by loading the package zip file into Winzip, and re-saving it.  I think there may be some incompatibility in format between a Winzip and SMF zip file.  I forget exactly how I solved the problem.  Either I used a zip program other than Winzip, or I got downloaded a fresh copy of the package, and did not open or save it with Winzip.

Let us know how you make out, since I was not sure exactly what was wrong in my case.


WinZip, IzArch and 7-Zip create zip archives SMF cannot read. Use WinRar (to create a zip), I use it for all my mods. Or any which can create a tar.gz.
Title: Re: Who Voted What?
Post by: remmons on January 21, 2009, 05:56:49 PM
Quote from: remmons on January 29, 2008, 05:48:21 PM
I basically got the mod working, but all the prompts are blank!  I am using the default themes with a freshly installed SMF v1.1.4.

When I go to "Admin / Feature and Options", there is a new selection box in the "Poll mode" section.  It has 3 choices, but their text is blank.  I tried selecting them anyhow, and found that the second showed a horizontal list of voters, and the third showed selection boxes of voters.  There is also no text next to the selection boxes.

When I go to "Admin/Permissions", there is a new check box in the "Poll" section, but no text to describe what the box does.  I guessed it allowed groups to see who voted what, so I checked it, and it did.

By the way, I had to zip the files with an old version of WinZip to get the package to upload without the "not a valid package / corrupted" message.  This must be an issue between WinZip and whatever SMF uses to unzip the package.

I'd feel a lot better about this mod if I could get the text to show.  How can I get the text to show properly?



YodaOfDarkness was correct after I upgraded to SMF v1.7.  I went to "Admin/Configuration/ServerSettings/CoreConfiguration", and set Default Forum Language to "English", not "English-UFT8", and the prompts appeared.
Title: Re: Who Voted What?
Post by: Rehash D Internet on January 31, 2009, 02:14:45 AM
Is this going to be released for 1.1.7?

Is there a way round it, otherwise?
Title: Re: Who Voted What?
Post by: nosferatu on January 31, 2009, 06:03:10 AM
Quote from: anand on January 20, 2009, 09:21:39 AM
Nobody seems to have a problem installing this...

I have downloaded the zip and tried to upload it under the packages section of the admin panel. When I upload the zip there it says that's it's an invalid or corrupt file I'm trying to upload. When I try to upload just the XML it says it won't accept XML.

Now I've uploaded the contents of the zip file to the packages folder on my webserver and it's being recognized only I can't install it. My only options are "list files" and "delete". How am I supposed to get this working?

A readme with just 4 or 5 steps contained in the zip would've been nice :)

I've used winrar to zip the file but I'm still getting just the view files and delete command in the Package manager. I have 'additional polls' installed so I'm wondering if there's a conflict with that. Is there some other way (via phpMyAdmin for instance) in which I can discover who has voted in a poll that is already running (and has 965 votes presently).

Thanks
Title: Re: Who Voted What?
Post by: Rehash D Internet on January 31, 2009, 06:27:24 AM
Quote from: Jessikard on November 10, 2008, 07:22:17 AM
i´ve installed this mod in my smf 1.1.7 and it works well

opened the package.xml and expand the version up to - 1.1.99
uploaded the package include the error in the display
then opened display.template.php via ftp and changed manually the parsed part

don´t forget the modification.*language*.php if you use others than engl.

activate in ACP Setting/Options - ready

You go be a bit more thorough with this? I love this mod and will miss it dearly if it doesn't get updated.
Title: Re: Who Voted What?
Post by: Gandalf123 on February 21, 2009, 11:31:28 AM
I've modified this add-on to work with SMF 2.0 RC1. As with the mod I did for Beta 3 & 3.1 I'm sharing this package with anyone here who would like to install this mod in their 2.0 RC1 forum.

I will be watching this thread so if you have any problems with my package just make a post in this thread and I will try to be here and help.

The enclosed file is for SMF 2.0 RC1 ONLY.

/Gandalf
Title: Re: Who Voted What?
Post by: Kindred on February 21, 2009, 01:40:53 PM
Sorry... attachment removed.

1- Do not re-release other people's mods unless you have permission to do so.
2- If you do wish to release your own version or update to the mod, use the mod site, not attachments.

Only mods on the mod site are checked for potential issues before being accepted.
Title: Re: Who Voted What?
Post by: Gandalf123 on February 21, 2009, 02:41:57 PM
I respect your decision in the matter.
I have no intention of starting my own mod nor taking over this one.
I only did it because I thought someone else might want it as well for their RC1 version.
It will not happen again.

/Gandalf
Title: Re: Who Voted What?
Post by: Doc.Blade on February 27, 2009, 02:41:30 AM
Has anyone got this or a similar mod available for SMF 1.1.8 at all?

Cheers in advance

Doc
Title: Re: Who Voted What?
Post by: Paracelsus on February 27, 2009, 03:53:36 AM
This MOD works for 1.1.8. It's not error free (you will get lots of errors in your log registry), but it works as it is supposed to.
Title: Re: Who Voted What?
Post by: Doc.Blade on February 27, 2009, 04:57:34 AM
Thank you muchly, i appreciate it :)
Title: Re: Who Voted What?
Post by: allymcbeal on February 27, 2009, 04:34:58 PM
Why means this code, what do it?

This file should not be able to execute standalone. You may have to run the following queries manually.


Query: [Select]
DELETE IGNORE FROM {$db_prefix}settings WHERE variable='whovotedwhatMode' LIMIT 1
Query: [Select]
INSERT IGNORE INTO {$db_prefix}settings (variable, value) VALUES ('whovotedwhatMode', 'disabled')
Title: Re: Who Voted What?
Post by: Doc.Blade on February 27, 2009, 10:14:56 PM
the mod wouldnt install for me on 1.1.8, said it wasnt compatible with this version of SMF.  Is anyone able to update the mod at all?
Title: Re: Who Voted What?
Post by: BAlGaInTl on March 11, 2009, 09:09:15 AM
I would be very interested in reviving this mod a well.  I rely on it for one of my forums.

It doesn't look like the author has maintained it in quite some time.
Title: Re: Who Voted What?
Post by: BAlGaInTl on March 11, 2009, 09:17:17 AM
I've attempted to contact the author via email to see if he would be willing to to update or allow someone else to update the project.

I don't have the skills to do it myself, but maybe someone else will be able to get it up and running again.

We will see how it goes.
Title: Re: Who Voted What?
Post by: Gwydion Frost on May 01, 2009, 10:17:58 PM
I am curious if the author or anyone else could resolve a small issue this mod has with the Additional Polls mod--

It displays the names of the voters in the order of the FIRST poll, regardless of the votes in the later polls.

Any fix to this would be greatly appreciated.
Title: Re: Who Voted What?
Post by: Ordogg on May 02, 2009, 12:18:54 AM
I want that fix that was removed for RC 2.0  Can you PM it to me?
Title: Re: Who Voted What?
Post by: Astra_200 on May 20, 2009, 09:08:53 AM
I to would like this mod for 2.0 RC1

Anybody got any plans to make it?  :)
Title: Re: Who Voted What?
Post by: gollum65 on May 25, 2009, 06:10:13 PM
I'd love to see this mod work for 2.0 RC1-1.  I have no idea how to do it though.  If anyone would be so kind....
Title: Re: Who Voted What?
Post by: Mayhem30 on May 26, 2009, 09:54:19 PM
How do I uninstall this mod?

There is no option for it in the package manager.
Title: Re: Who Voted What?
Post by: vicious_pucca on May 27, 2009, 04:52:48 PM
I would like one for 2.0 RC1-1 as well.
Title: Re: Who Voted What?
Post by: darth_dionysus on May 31, 2009, 07:00:00 AM
I'll put another vote in for somebody adapting this mod for 2.0 RC1-1.  Any takers?
Title: Re: Who Voted What?
Post by: Mayhem30 on June 02, 2009, 01:52:23 AM
Could someone please tell me how to uninstall this mod? (Second request)

It can't be done via package manager.

Thanks.
Title: Re: Who Voted What?
Post by: Gandalf123 on June 02, 2009, 11:09:42 AM
You need to emulate back to the SMF version you had when you installed it.
Go to the package manager, once there, append --> ;emulate_version=1.1.x <--- in the url where 1.1.x would be the version you had when you installed this mod.
The uninstall button will then appear for you so you can uninstall it.
Title: Re: Who Voted What?
Post by: Mayhem30 on June 02, 2009, 09:18:53 PM
No, that's not the issue.

This is the message I'm getting :

This package cannot be uninstalled, because there is no uninstaller!
Please contact the mod author for more information.
Title: Re: Who Voted What?
Post by: Mayhem30 on June 16, 2009, 11:44:31 PM
I'm not getting any "uninstall button".

Would there be any issues if I manually typed this in the URL box?

http://www.pogocheats.net/forum/index.php?action=packages;sa=uninstall;package=who_voted_what_1-1-3-Editedfor1.1.8.zip
Title: Re: Who Voted What?
Post by: asifnur on June 29, 2009, 11:19:37 PM
can i have yhis for 1.1.9 please
Title: Re: Who Voted What?
Post by: Paracelsus on June 30, 2009, 04:49:01 AM
A quick tuning:

Those who get lots (thousands) of errors in their forum logs with elements like "option", "bar", "vote", etc, check this in Display.template.php:

<td nowrap="nowrap">

And change it to:
<td style="white-space:nowrap;">

I think it's more "XHTML compliant" and it worked for me. ;)
Title: Re: Who Voted What?
Post by: patestuta on July 05, 2009, 03:45:49 PM
Has anybody been able to install some version to 2.0 RC1-1?
Title: Re: Who Voted What?
Post by: Søren Bjerg on July 12, 2009, 06:37:56 AM
Sorry for falling off the face of Earth once again, but I'll happily give permission to someone else to take over the development of the modification.
Title: Re: Who Voted What?
Post by: goforit on July 19, 2009, 07:07:46 AM
Quote from: Søren Bjerg on July 12, 2009, 06:37:56 AM
Sorry for falling off the face of Earth once again, but I'll happily give permission to someone else to take over the development of the modification.
The install worked for me, and option all work, at the moment i have a drop down next to each option in the poll, the only thing i need to know; how does it select who voted, is it by IP or is it by username?... reason i ask is because if for example 10 people voted in one choice, many more than 10 people are listed in the drop down menu, this suggests to me that the selection is chosen based on IP...is this correct and if so, could it be changed to username?

Reason why is that AOL and some other companies use proxy IPs which means different users use the same proxy IP..so anyone using say AOL and voted in that poll, the poll will show more than one vote, it will show every member who using AOL in that region.
Title: Re: Who Voted What?
Post by: Søren Bjerg on July 19, 2009, 07:36:19 AM
Quote from: goforit on July 19, 2009, 07:07:46 AM
Quote from: Søren Bjerg on July 12, 2009, 06:37:56 AM
Sorry for falling off the face of Earth once again, but I'll happily give permission to someone else to take over the development of the modification.
The install worked for me, and option all work, at the moment i have a drop down next to each option in the poll, the only thing i need to know; how does it select who voted, is it by IP or is it by username?... reason i ask is because if for example 10 people voted in one choice, many more than 10 people are listed in the drop down menu, this suggests to me that the selection is chosen based on IP...is this correct and if so, could it be changed to username?

Reason why is that AOL and some other companies use proxy IPs which means different users use the same proxy IP..so anyone using say AOL and voted in that poll, the poll will show more than one vote, it will show every member who using AOL in that region.
It should - if I remember correctly - pull the votes cast from the database table. That's at least how it worked initially.
Title: Re: Who Voted What?
Post by: goforit on July 19, 2009, 11:03:31 AM
Quote from: Søren Bjerg on July 19, 2009, 07:36:19 AM
Quote from: goforit on July 19, 2009, 07:07:46 AM
Quote from: Søren Bjerg on July 12, 2009, 06:37:56 AM
Sorry for falling off the face of Earth once again, but I'll happily give permission to someone else to take over the development of the modification.
The install worked for me, and option all work, at the moment i have a drop down next to each option in the poll, the only thing i need to know; how does it select who voted, is it by IP or is it by username?... reason i ask is because if for example 10 people voted in one choice, many more than 10 people are listed in the drop down menu, this suggests to me that the selection is chosen based on IP...is this correct and if so, could it be changed to username?

Reason why is that AOL and some other companies use proxy IPs which means different users use the same proxy IP..so anyone using say AOL and voted in that poll, the poll will show more than one vote, it will show every member who using AOL in that region.
It should - if I remember correctly - pull the votes cast from the database table. That's at least how it worked initially.
thanks for the quick reply... i have just checked the way it looks again and noticed that it does not count users from IP, i noticed in my case that the extra names are not extra at all, they are double, the names are correct to the reported total, but in the drop down it shows two lists of the same names...that is what confused me...is their a way of editing some code to sort this out?
Title: Re: Who Voted What?
Post by: Eliana Tamerin on July 19, 2009, 11:55:56 AM
Søren, is there any chance you're interested in updating this for SMF 2.0? Or are you just looking to get rid of the mod?
Title: Re: Who Voted What?
Post by: Søren Bjerg on July 20, 2009, 09:39:57 AM
In all honestly I haven't followed development of SMF since... uhh, I think my forum was left at 1.1.3 when I found a use for it again.

I could probably set up a development environment and delve into how stuff works - or will work in 2.0 - in SMF to make a 2.0 version of the modification, though a more able and experienced coder would probably be preferred (my code may work - sometimes - but it isn't exactly pretty)?
Title: Re: Who Voted What?
Post by: Rehash D Internet on July 23, 2009, 02:42:16 PM
I'd love this for 1.1.10. This was one of my favourite mods.
Title: Re: Who Voted What?
Post by: sepulchre on July 28, 2009, 03:43:21 AM
I hope someone takes up the mod for v2.0 as this would be very handy for me :)
Title: Re: Who Voted What?
Post by: [A-US]James246 on July 28, 2009, 08:31:33 AM
Nothing seems to happen when I install it and apply it.

I can't see any options to see who voted for what or anything.

Please help! Thanks!
Title: Re: Who Voted What?
Post by: drhamza on July 30, 2009, 04:11:52 AM
Søren, can't you just give the permission for gandalf to add the 2.0 version... that would be very kind of you
thanks in advance
Title: Re: Who Voted What?
Post by: giovannie_a2a on July 31, 2009, 10:26:46 AM
I would love to see this mod working for SMF 2.0 1-2
Title: Re: Who Voted What?
Post by: [A-US]James246 on August 01, 2009, 08:20:38 AM
Quote from: [A-US]James246 on July 28, 2009, 08:31:33 AM
Nothing seems to happen when I install it and apply it.

I can't see any options to see who voted for what or anything.

Please help! Thanks!

Anyone? Help?
Title: Re: Who Voted What?
Post by: Blinker on August 02, 2009, 01:46:12 AM
[A-US]James246 - Have you checked the mod settings in Features and Options > Basic Features > Who Voted What? mode?

You need to select either "select box" or "table view". It defaults to disabled when the mod is first installed.
Title: Re: Who Voted What?
Post by: [A-US]James246 on August 02, 2009, 03:58:53 AM
I re-installed it and it worked, but now there is an error.

It shows up the peoples name twice.

E.G.

Question:      What MW2 edition will you get?
Normal    -
[A-US]James246 [A-US]James246    1    100%
Prestige    -
   0    0%
Hardened    -
   0    0%
   Lock Voting
Edit Poll
Total Voters: 1

It shows up the name of the voter twice.

How can I fix this?
Title: Re: Who Voted What?
Post by: Blinker on August 02, 2009, 04:02:23 AM
You've probably got some code doubled up somewhere from the multiple installs.

You're going to have to look through all the files the mod edits and search for the code it inserts. Anywhere you see the code appearing twice you'll need to edit out the duplicate code.
Title: Re: Who Voted What?
Post by: [A-US]James246 on August 02, 2009, 04:53:52 AM
What file would this be in?
Title: Re: Who Voted What?
Post by: Blinker on August 02, 2009, 05:15:00 AM
All the files that the mod has edited. You need to go to the mod's page here - http://mods.simplemachines.org/index.php?mod=347

Select v1.1.9 (I assume that's the one you're using) and then select SMF v1.1.9 from the dropdown menu and click "parse".

That will show you all the files from your forum that the mod edits. You are going to have to manually check every one of them. Do you know how to do that? If not follow this link - Manual Installation of Mods (http://docs.simplemachines.org/index.php?topic=402)

Title: Re: Who Voted What?
Post by: FightToTheDeath on August 17, 2009, 09:26:51 AM
How can i make it work with 1.1.10 ?
Title: Re: Who Voted What?
Post by: Kroy on August 25, 2009, 04:17:04 PM
another bump if anyone would be willing to take this one on for 2.0 1-1, 1-2. Much appreciated.

Though, it should include an option to set on poll creation whether or not the poll participants are visible rather than all Mods/admin seeing all polls?
Title: Re: Who Voted What?
Post by: aw06 on September 07, 2009, 12:15:11 AM
Quote from: FightToTheDeath on August 17, 2009, 09:26:51 AM
How can i make it work with 1.1.10 ?

bump
Title: Re: Who Voted What?
Post by: Sabre™ on September 07, 2009, 12:23:01 AM
Attached is the package which will work on smf 1.1.10
I will remove it when the mod author has time to update :)
Title: Re: Who Voted What?
Post by: wilsy on September 10, 2009, 03:29:31 AM
Quote from: Sabre™ on September 07, 2009, 12:23:01 AM
Attached is the package which will work on smf 1.1.10
I will remove it when the mod author has time to update :)

Hi Sabre,

Im getting - The package you are trying to download or install is either corrupt or not compatible with this version of SMF.

Any ideas?
Title: Re: Who Voted What?
Post by: Sabre™ on September 10, 2009, 06:27:34 PM
Yep, my bad mate, I just read up on why it wasn't working.
Try this attached one.
Title: Re: Who Voted What?
Post by: Ezechiele on September 11, 2009, 06:51:22 AM
It works !!!!

Thx  ;)
Title: Re: Who Voted What?
Post by: Nameless? on September 11, 2009, 01:45:06 PM
will this be upgraded to 2.0 rc1.2 ?
Title: Re: Who Voted What?
Post by: TwitchisMental on September 11, 2009, 05:32:17 PM
This would be a great 2.0 mod.
Title: Re: Who Voted What?
Post by: Sabre™ on September 11, 2009, 07:21:35 PM
It looks easy enough to port to SMF2, but writing the db part is where I usually fall short when updating mods for my own use.
Since I know nothing about that sort of stuff, I think it may be a good time to learn huh? lol ;)
I think someone is updating this mod anyhow.
But if not, I'll give it a shot sometime next week.
A 'reminding' bump would be good maybe on Tuesday if you're interested, otherwise I may forget
Title: Re: Who Voted What?
Post by: Eliana Tamerin on September 11, 2009, 07:24:01 PM
I've rewritten this for 2.0, I'm just working on the templating stuff. I'd like to handle it with JS instead of having ugly dropdown boxes or a bunch of names staring out at you. So hopefully, the interface shouldn't look too different than what normal users see.
Title: Re: Who Voted What?
Post by: Sabre™ on September 11, 2009, 07:25:57 PM
Nice!
Thanks for the update Eliana :)
Title: Re: Who Voted What?
Post by: villasg on September 12, 2009, 01:40:02 PM
Quote from: Sabre™ on September 10, 2009, 06:27:34 PM
Yep, my bad mate, I just read up on why it wasn't working.
Try this attached one.

Hi sabre can i ask you ?
This " who_voted_what_1-1-x.zip"  from quoted post work in my 1.1.10 smf ?
Please tell me or upload a workink version fro 1.1.10 .
Thanks and sorry !
Title: Re: Who Voted What?
Post by: Sabre™ on September 12, 2009, 04:35:00 PM
Yes buddy, it will work for smf 1.1.10 :)
Title: Re: Who Voted What?
Post by: TwitchisMental on September 12, 2009, 07:41:21 PM
Quote from: Eliana Tamerin on September 11, 2009, 07:24:01 PM
I've rewritten this for 2.0, I'm just working on the templating stuff. I'd like to handle it with JS instead of having ugly dropdown boxes or a bunch of names staring out at you. So hopefully, the interface shouldn't look too different than what normal users see.
Thanks for updating it :D.
Title: Re: Who Voted What?
Post by: City Builder on October 02, 2009, 04:46:09 PM
I tried to install it in 1.1.10 but was shown the message saying that it is either corrupt or not for my version of smf!?!
Title: Re: Who Voted What?
Post by: hvyhitter on October 04, 2009, 10:36:54 AM
totally says for 1.1.9 only :)

i want this for the latest beta ! :)

Ahh it would seem one page back is is being developed.

Well.. EXCELLENT.

thx! i will be back.


Title: Re: Who Voted What?
Post by: sepulchre on October 07, 2009, 09:19:22 AM
Countess Tamerin, any news on the upgrade of this mod to v2? I'd be delighted to hear its on its way.

Thanks :)
Title: Re: Who Voted What?
Post by: Eliana Tamerin on October 07, 2009, 09:45:56 AM
With the release of RC2 to the charters (and hopefully soon to the public), I've had a renewed interest in this. It shouldn't be long until its done.
Title: Re: Who Voted What?
Post by: rufen on November 17, 2009, 09:17:27 PM
nice! I would really like to have that one on RC2!
Title: Re: Who Voted What?
Post by: adbrad on November 22, 2009, 05:22:55 PM
This mod would be useful on my forum I'm running 2.0 RC1.2. Would like this mod on this version as i have no way of upgrading to RC2 yet as some of the mods i use, and the theme i have are not compatible yet.
This mod would be useful as, I am intending on running some photo comps, and users will not be allowed to vote on their own photo, so would need to see who's voted.
Title: Re: Who Voted What?
Post by: adbrad on November 25, 2009, 05:14:39 AM
been looking round the forum and see this had been updated to work with 2.0 beta.
Would some one be able to update to rc1.2, rc2 the package can be down loaded here
http://www.simplemachines.org/community/index.php?topic=110220.msg1586982#msg1586982
Title: Re: Who Voted What?
Post by: rufen on November 29, 2009, 01:42:32 PM
yes, that would be really nice!
Title: Re: Who Voted What?
Post by: drhamza on November 30, 2009, 12:50:24 AM
Quote from: Eliana Tamerin on October 07, 2009, 09:45:56 AM
With the release of RC2 to the charters (and hopefully soon to the public), I've had a renewed interest in this. It shouldn't be long until its done.
Title: Re: Who Voted What?
Post by: rufen on November 30, 2009, 07:38:37 AM
well it's been almost 2 months. ;)
Title: Re: Who Voted What?
Post by: drhamza on November 30, 2009, 08:25:52 AM
wow, that was fast! soo, where are you eliana :D
Title: Re: Who Voted What?
Post by: alexandervba on December 13, 2009, 06:48:46 AM
is there a version for 1.1.11 ?

thank u.
Title: Re: Who Voted What?
Post by: gary80920 on December 16, 2009, 09:04:09 PM
Quote from: Sabre™ on September 10, 2009, 06:27:34 PM
Yep, my bad mate, I just read up on why it wasn't working.
Try this attached one.

I installed the package. And it appeared to install okay.

However, the privilege is blank. I looked at the instructions on how to apply the mods manually to verify correct installation. And the code appears to be there.

Please see the attached screenshots.

Thanks,
Gary
Title: Re: Who Voted What?
Post by: ChaosEnergy on December 27, 2009, 12:07:25 PM
any news on a smf2 rc2 version?
Title: Re: Who Voted What?
Post by: rufen on January 01, 2010, 05:53:31 PM
I sent her a message, no reply.
Title: Re: Who Voted What?
Post by: XtcruleZ on January 16, 2010, 12:29:06 PM
Quote from: ChaosEnergy on December 27, 2009, 12:07:25 PM
any news on a smf2 rc2 version?

I am interested in this also.
Title: Re: Who Voted What?
Post by: mghome59 on January 17, 2010, 01:32:21 PM
It`s working good ...  on SMF 2.0 RC2

Many thanks to Gandalf123
Title: Re: Who Voted What?
Post by: XtcruleZ on January 17, 2010, 11:48:29 PM
How did you get it to work?
Title: Re: Who Voted What?
Post by: adbrad on January 18, 2010, 04:51:40 AM
Quote from: XtcruleZ on January 17, 2010, 11:48:29 PM
How did you get it to work?
would also like to know this
Title: Re: Who Voted What?
Post by: mghome59 on January 18, 2010, 06:19:36 AM
Gandalf123 did the job for 2.0 RC1.2. I just did the small change for RC2. For the package just send me a PM whit your email address. I can`t post it here without autor approval.
Title: Re: Who Voted What?
Post by: XtcruleZ on January 18, 2010, 06:36:33 AM
Thank you.
Title: Re: Who Voted What?
Post by: adbrad on January 18, 2010, 08:05:17 AM
Quote from: mghome59 on January 18, 2010, 06:19:36 AM
Gandalf123 did the job for 2.0 RC1.2. I just did the small change for RC2. For the package just send me a PM whit your email address. I can`t post it here without autor approval.

still can't get it working
Title: Re: Who Voted What?
Post by: XtcruleZ on January 18, 2010, 05:57:33 PM
Me either. I wish he would "officially" update this to work with RC2.
Title: Re: Who Voted What?
Post by: Nazgul1 on January 19, 2010, 01:45:16 PM
Please, send me too information what i must do for RC2  (PM). (sorry for bad english)
Title: Re: Who Voted What?
Post by: mghome59 on January 19, 2010, 04:07:29 PM
I updated package and tested ...  I will try to post it here and hope for the best :D
Title: Re: Who Voted What?
Post by: adbrad on January 19, 2010, 05:01:53 PM
still not working on my forum
Title: Re: Who Voted What?
Post by: mghome59 on January 19, 2010, 05:14:03 PM
Quote from: adbrad on January 19, 2010, 05:01:53 PM
still not working on my forum

I have tested on SMF 2.0 RC2 clean install. Tell me what error do you have and maybe I can help you ?

Title: Re: Who Voted What?
Post by: adbrad on January 19, 2010, 05:24:35 PM
had error on display.template so did the edit and still not showing the names of people who voted.
this is test poll
http://caringforhuskies.com/forum2/general-discussion/annouce/
Title: Re: Who Voted What?
Post by: mghome59 on January 19, 2010, 07:12:18 PM
Quote from: adbrad on January 19, 2010, 05:24:35 PM
had error on display.template so did the edit and still not showing the names of people who voted.
this is test poll
http://caringforhuskies.com/forum2/general-discussion/annouce/

did you clear the cache of your forum ?
Title: Re: Who Voted What?
Post by: adbrad on January 19, 2010, 07:55:05 PM
yes
Title: Re: Who Voted What?
Post by: XtcruleZ on January 21, 2010, 07:13:05 AM
I get this error when installing the updated version:

6.     Execute Modification     ./Themes/default/Display.template.php     Test failed
1.     Replace     ./Themes/default/Display.template.php     Test failed
Title: Re: Who Voted What?
Post by: mghome59 on January 21, 2010, 08:47:21 AM
Quote from: XtcruleZ on January 21, 2010, 07:13:05 AM
I get this error when installing the updated version:

6.     Execute Modification     ./Themes/default/Display.template.php     Test failed
1.     Replace     ./Themes/default/Display.template.php     Test failed

Pls attach your Display.template.php
Title: Re: Who Voted What?
Post by: Verso on January 21, 2010, 09:01:29 AM
Please ignore the PM I sent. I found the latest version when I read more of the forum!

I get this error when installing the updated version:

6.     Execute Modification     ./Themes/default/Display.template.php     Test failed
1.     Replace     ./Themes/default/Display.template.php     Test failed


I have included my Display.template.php
Title: Re: Who Voted What?
Post by: Verso on January 21, 2010, 09:18:50 AM
Nope......

If you look at my link it's gone a bit awry

http://www.suffolksportsforum.co.uk/2010-sports-awards/suffolk-sports-forum-awards-the-nominees-team-of-the-year/
Title: Re: Who Voted What?
Post by: mghome59 on January 21, 2010, 09:45:25 AM
Hope it`s ok now. Uninstall previous, then delete it, upload this one.  Don`t forget to clean your cache (from forum root) and enable who voted what from 

    * Forum » Administration Center » Features and Options
Title: Re: Who Voted What?
Post by: Verso on January 21, 2010, 09:59:22 AM
Nice one.

Title: Re: Who Voted What?
Post by: mghome59 on January 21, 2010, 10:02:31 AM
Quote from: Verso on January 21, 2010, 09:59:22 AM
Nice one.

It`s not ok on your forum ... pls check if you have poll_middle.gif, poll_left.gif and poll_right.gif on your "Themes/default/images/" folder and ofcourse you permision ..

Now even guest can see who voted what  :D
Title: Re: Who Voted What?
Post by: Verso on January 21, 2010, 10:16:01 AM
It is now!

Cheers bud
Title: Re: Who Voted What?
Post by: mghome59 on January 21, 2010, 10:17:11 AM
Quote from: Verso on January 21, 2010, 10:16:01 AM
It is now!

Cheers bud


I`m glad to help   ;)
Title: Re: Who Voted What?
Post by: 7s-1k on January 21, 2010, 10:26:20 AM
Hmm.. I've selected the 'view voters' option (permission) but when I check at the poll I can't find who voted what..
Title: Re: Who Voted What?
Post by: mghome59 on January 21, 2010, 10:29:22 AM
Quote from: 7s-1k on January 21, 2010, 10:26:20 AM
Hmm.. I've selected the 'view voters' option (permission) but when I check at the poll I can't find who voted what..

did you clear your cache after install the mod and enable from Forum » Administration Center » Features and Options ?
Title: Re: Who Voted What?
Post by: Verso on January 21, 2010, 10:33:59 AM
Quote from: 7s-1k on January 21, 2010, 10:26:20 AM
Hmm.. I've selected the 'view voters' option (permission) but when I check at the poll I can't find who voted what..

My turn to help now......

Have you edited permissions?
Title: Re: Who Voted What?
Post by: mghome59 on January 21, 2010, 10:37:50 AM
If he `s admin there is no need to edit permission to see who voted what. Just enable the mod from the admin panel. 
Title: Re: Who Voted What?
Post by: 7s-1k on January 21, 2010, 11:43:13 AM
I'm admin, so I thought I should see who voted what.. But I cant see it.
Title: Re: Who Voted What?
Post by: mghome59 on January 21, 2010, 12:51:12 PM
Quote from: 7s-1k on January 21, 2010, 11:43:13 AM
I'm admin, so I thought I should see who voted what.. But I cant see it.

You did not answer my question ....

do you clear your cache after install the mod, and enable it from Forum » Administration Center » Features and Options ?
Title: Re: Who Voted What?
Post by: adbrad on January 21, 2010, 01:52:31 PM
Quote from: mghome59 on January 21, 2010, 12:51:12 PM
enable it from Forum » Administration Center » Features and Options ?

thankyou this is the bit i was missing it never showed in my first install working perfect now
Title: Re: Who Voted What?
Post by: blunt on January 21, 2010, 02:29:51 PM
Quote from: alexandervba on December 13, 2009, 06:48:46 AM
is there a version for 1.1.11 ?

thank u.

I'd also like to know. I've just had somebody join the forum on the same ip addy as another user, and I suspect that user might be cloning himself in order to skew poll votes. Though it's not life or death important, I'd be fascinated to see if this is the case, and if it is, catch him at it :D
Title: Re: Who Voted What?
Post by: 7s-1k on January 21, 2010, 02:46:46 PM
Quote from: adbrad on January 21, 2010, 01:52:31 PM
Quote from: mghome59 on January 21, 2010, 12:51:12 PM
enable it from Forum » Administration Center » Features and Options ?

thankyou this is the bit i was missing it never showed in my first install working perfect now

I agree..

Thanks mghome59 it works fine!
Title: Re: Who Voted What?
Post by: XtcruleZ on January 21, 2010, 04:49:03 PM
The latest version works flawlessly!! Thank you very much for updating this.
Title: Re: Who Voted What?
Post by: blunt on January 23, 2010, 04:29:12 PM
So, is there a version for 1.1.11 ? ???
Title: Re: Who Voted What?
Post by: Nick Whetstone on January 23, 2010, 06:11:57 PM
I did a couple of quick edits to the package so it will install cleanly on 1.1.11... This attachment worked for me.

*Note* If the mod author would prefer I take this down, just let me know.
Title: Re: Who Voted What?
Post by: drhamza on January 24, 2010, 09:35:17 AM
btw, if you have the multiple polls mod installed, this mod won't work ;)
Title: Re: Who Voted What?
Post by: blunt on January 24, 2010, 05:50:55 PM
Thanks, Ha² - much appreciated :)
Title: Re: Who Voted What?
Post by: blunt on January 24, 2010, 05:57:36 PM
Except it doesn't work :(
Title: Re: Who Voted What?
Post by: adbrad on January 24, 2010, 06:10:51 PM
Quote from: adbrad on January 21, 2010, 01:52:31 PM
Quote from: mghome59 on January 21, 2010, 12:51:12 PM
enable it from Forum » Administration Center » Features and Options ?

thankyou this is the bit i was missing it never showed in my first install working perfect now

it will only work perfect on the core theme on the curve theme which i use it stops showing the bars for the percentage of votes
Title: Re: Who Voted What?
Post by: blunt on January 24, 2010, 06:31:41 PM
Ah - but it does work on the SMF default theme :) I can live with that. Thanks.
Title: Re: Who Voted What?
Post by: Nick Whetstone on January 24, 2010, 07:38:51 PM
Quote from: blunt on January 24, 2010, 06:31:41 PM
Ah - but it does work on the SMF default theme :) I can live with that. Thanks.
Was gonna say... lol.
Title: Re: Who Voted What?
Post by: mghome59 on January 24, 2010, 11:56:55 PM
Quote from: adbrad on January 24, 2010, 06:10:51 PM
Quote from: adbrad on January 21, 2010, 01:52:31 PM
Quote from: mghome59 on January 21, 2010, 12:51:12 PM
enable it from Forum » Administration Center » Features and Options ?

thankyou this is the bit i was missing it never showed in my first install working perfect now

it will only work perfect on the core theme on the curve theme which i use it stops showing the bars for the percentage of votes

pls check if you have poll_middle.gif, poll_left.gif and poll_right.gif on your "$themedir/images/" folder
Title: Re: Who Voted What?
Post by: adbrad on January 25, 2010, 04:34:48 AM
Quote from: mghome59 on January 24, 2010, 11:56:55 PM
Quote from: adbrad on January 24, 2010, 06:10:51 PM
Quote from: adbrad on January 21, 2010, 01:52:31 PM
Quote from: mghome59 on January 21, 2010, 12:51:12 PM
enable it from Forum » Administration Center » Features and Options ?

thankyou this is the bit i was missing it never showed in my first install working perfect now

it will only work perfect on the core theme on the curve theme which i use it stops showing the bars for the percentage of votes

pls check if you have poll_middle.gif, poll_left.gif and poll_right.gif on your "$themedir/images/" folder

ok where do i get the images from are they in the mod file
Title: Re: Who Voted What?
Post by: mghome59 on January 25, 2010, 04:20:41 PM
Quote

ok where do i get the images from are they in the mod file

here
Title: Re: Who Voted What?
Post by: adbrad on January 25, 2010, 05:56:21 PM
Quote from: mghome59 on January 25, 2010, 04:20:41 PM
Quote

ok where do i get the images from are they in the mod file

here

thankyou works fine now
Title: Re: Who Voted What?
Post by: Stigmartyr on February 01, 2010, 08:30:20 PM
Anything like this for SMF 2.0?
Title: Re: Who Voted What?
Post by: adbrad on February 02, 2010, 04:40:39 AM
Quote from: Stigmartyr on February 01, 2010, 08:30:20 PM
Anything like this for SMF 2.0?

try the package in this message
http://www.simplemachines.org/community/index.php?topic=110220.msg2466734#msg2466734
it worked for me
Title: Re: Who Voted What?
Post by: Shades. on February 02, 2010, 08:16:43 PM
Quote from: adbrad on February 02, 2010, 04:40:39 AM
Quote from: Stigmartyr on February 01, 2010, 08:30:20 PM
Anything like this for SMF 2.0?

try the package in this message
http://www.simplemachines.org/community/index.php?topic=110220.msg2466734#msg2466734
it worked for me

Worked like a charm in rc2, thanks a million! :)
Title: Re: Who Voted What?
Post by: rufen on February 07, 2010, 10:51:27 AM
works great! thank you very mucH!
Title: Re: Who Voted What?
Post by: Stigmartyr on February 07, 2010, 01:52:33 PM
Does this allow regular members to view the poll results, too?
Title: Re: Who Voted What?
Post by: mghome59 on February 07, 2010, 01:55:14 PM
nope. only with your permission
Title: Re: Who Voted What?
Post by: gm112 on February 13, 2010, 02:49:32 PM
Removed the need for the classic SMF poll images. Was a simple change, really.. O_o.

Title: Re: Who Voted What?
Post by: ice-be on February 25, 2010, 07:42:15 AM
Quote from: drhamza on January 24, 2010, 09:35:17 AM
btw, if you have the multiple polls mod installed, this mod won't work ;)

Ah. That's why I keep failing.

Might there be a way to fix this? I really need both mods to work.
Title: Re: Who Voted What?
Post by: Rehash D Internet on March 08, 2010, 01:26:47 PM
Quote from: Ha² on January 23, 2010, 06:11:57 PM
I did a couple of quick edits to the package so it will install cleanly on 1.1.11... This attachment worked for me.

*Note* If the mod author would prefer I take this down, just let me know.

I've applied this to my 1.1.11 and it apparently installed cleanly but the results still aren't showing. Any ideas?
Title: Re: Who Voted What?
Post by: adbrad on March 12, 2010, 05:16:21 PM
anyone going to be updating for rc3?
Title: Re: Who Voted What?
Post by: drhamza on March 12, 2010, 10:30:08 PM
Quote from: adbrad on March 12, 2010, 05:16:21 PM
anyone going to be updating for rc3?
second that
Title: Re: Who Voted What?
Post by: Shades. on March 13, 2010, 06:45:24 AM
Quote from: drhamza on March 12, 2010, 10:30:08 PM
Quote from: adbrad on March 12, 2010, 05:16:21 PM
anyone going to be updating for rc3?
second that
I third that! ;)
Title: Re: Who Voted What?
Post by: sepulchre on March 16, 2010, 05:53:09 PM
looking forward to seeing this in rc3  ;D
Title: Re: Who Voted What?
Post by: Sharb8 on March 17, 2010, 04:41:39 AM
i want this for 1.1.11
Title: Re: Who Voted What?
Post by: adbrad on March 23, 2010, 05:42:28 PM
mod author not been online since December20 2009 so not sure if he is still supporting the mod
Title: Re: Who Voted What?
Post by: koops on May 31, 2010, 01:07:27 AM
Has anyone modded the gm112 version of this for rc3?

I've tried the "emulate" option and chosen rc 2 from gm112's version and it "only" errors on the DIsplay.template.php file.
Title: Re: Who Voted What?
Post by: juvebalkan on May 31, 2010, 02:22:53 PM
Adapted for 2.0 RC3 by me....

I tested it and it's working good... :)
Title: Re: Who Voted What?
Post by: Kindred on May 31, 2010, 02:58:29 PM
juve,

please do not release your own versions of other people's mods...   The original author's last active date is just last week, so this mod can not be termed "abandoned", and as such, you can not distribute your own copy without the author's permission.   Alos, attaching a mod in a thread is BAD process, since it means that none of the SMF team have reviewed it for compliance with coding process or for safety.
Title: Re: Who Voted What?
Post by: juvebalkan on May 31, 2010, 03:04:52 PM
No, I didn't say it's my version, I just said it's adopted for RC3 and that's it...I didn't remove anything from the source code, original author or anything. In past posts, the creator of this post gave permission as I saw for anyone who can adopt this mod for some new version of SMF. Since none made it available for RC3, I thought I might help.

I tested it on my own forum, and it is working without any problems. You can remove it and review it, it's not a problem.

Sorry if I caused some trouble, intention was to help, otherwise I would keep this to myself... :)
Title: Re: Who Voted What?
Post by: sepulchre on May 31, 2010, 04:15:36 PM
Well I checked this thread earlier from my phone and was delighted someone had finally done what none of the rest of us could do and updated this mod for RC3, its just a pity this has been removed, I understand the reasons but this mod had been dead for months, the author hasn't even replied to this thread since -

Quote from: Søren Bjerg on July 20, 2009, 09:39:57 AM
In all honestly I haven't followed development of SMF since... uhh, I think my forum was left at 1.1.3 when I found a use for it again.

I could probably set up a development environment and delve into how stuff works - or will work in 2.0 - in SMF to make a 2.0 version of the modification, though a more able and experienced coder would probably be preferred (my code may work - sometimes - but it isn't exactly pretty)?

Surely this mod must be "abandoned" by now in anyone's terms? Can the mod be released or in the very least examined by SMF?

Thanks
Title: Re: Who Voted What?
Post by: Kindred on May 31, 2010, 08:53:21 PM
if someone submits it to the mod site, yes, the team can and will review it.
Title: Re: Who Voted What?
Post by: koops on June 01, 2010, 07:48:30 PM
Quote from: juvebalkan on May 31, 2010, 03:04:52 PM
No, I didn't say it's my version, I just said it's adopted for RC3 and that's it...I didn't remove anything from the source code, original author or anything. In past posts, the creator of this post gave permission as I saw for anyone who can adopt this mod for some new version of SMF. Since none made it available for RC3, I thought I might help.

I tested it on my own forum, and it is working without any problems. You can remove it and review it, it's not a problem.

Sorry if I caused some trouble, intention was to help, otherwise I would keep this to myself... :)

I think the other way you can do this all within the rules would be to post the code and the files that you changed (if there isn't an huge rewrite).

This way you've provided the information on how to make it work for people that want it while also not violating any other rules.

This is a mod that still has people interested in getting working for 2.0rc3 so I for one would be very interested in it ;)
Title: Re: Who Voted What?
Post by: koops on June 01, 2010, 10:06:45 PM
For those trying to get it to install on rc3 the change is a simple one from the rc2 version that was already posted.

All juvebalkan's version changes was the following

QuoteOn the line 4, instead of   

<install for="2.0 RC2">
I put
<install for="2.0 RC3">

On the line 18, instead of
<uninstall for="2.0 RC2">
I put
<uninstall for="2.0 RC3">

Thats it! All kudos to juvebalkan :D

So you'll just have to manually extract, edit and then repackage the files and it should allow you to install it.

edit: I had to manually re-edit the display.template.php file to comment out an extra "}" in the code to get it to work correctly. The main foreach function add's an extra "}" that wasn't in the original template code.
Title: Re: Who Voted What?
Post by: koops on June 02, 2010, 12:54:54 AM
Does any one know the php code to put in to get the colored bar back in addition to the names?

I though it was this :

around line 47 find
<dd class="middletext statsbar', $option['voted_this'] ? ' voted' : '', '">

and append this after it.

<dd class="middletext statsbar', $option['voted_this'] ? ' voted' : '', '">

I then get the html code for bar in the page source like this :

ie. <div class="bar" style="width: 148.2px;"><div style="width: 144.2px;">

But nothing is visible.
Title: Re: Who Voted What?
Post by: Dark//Virus on June 02, 2010, 05:03:33 PM
I installed this mod in RC3, removed the extra } bracket, but i dont see where i can view the voters, unless it doesnt count if i am a voter?
Title: Re: Who Voted What?
Post by: adbrad on June 02, 2010, 05:29:26 PM
Quote from: Dark//Virus on June 02, 2010, 05:03:33 PM
I installed this mod in RC3, removed the extra } bracket, but i dont see where i can view the voters, unless it doesnt count if i am a voter?

have you enabled in admin.

Quote from: adbrad on January 21, 2010, 01:52:31 PM
Quote from: mghome59 on January 21, 2010, 12:51:12 PM
enable it from Forum » Administration Center » Features and Options ?

thankyou this is the bit i was missing it never showed in my first install working perfect now
Title: Re: Who Voted What?
Post by: Dark//Virus on June 07, 2010, 06:23:32 PM
Yes, i beleive its enabled

Anywho, we are customizing this mod so instead of global permissions/change

It has a tick box when creating the poll to make it anonymous or open
Title: Re: Who Voted What?
Post by: chinaren on July 03, 2010, 07:07:47 AM
Hi, just looking through some of the recent posts here, but it's a bit muddled.


Would the updated/amended ('unofficial') version of this work on 2RC3 with multiple polls mod on?  I'd really quite like it.


Also:


QuoteAnywho, we are customizing this mod so instead of global permissions/change

It has a tick box when creating the poll to make it anonymous or open



Does this mean you've done this already, or still working on it?  If so, is the code posted somewhere here?  Also, when you say anonymous, do you mean that it will just show who's voted, but not what for?


Sorry to ask so many questions!
Title: Re: Who Voted What?
Post by: ljsevern on July 12, 2010, 08:20:55 PM
Sorry for the necro bump, but I would love a mod that does this in 1.1.11
Title: Re: Who Voted What?
Post by: miDnIghtEr20C on August 13, 2010, 07:37:41 PM
Quote from: ljsevern on July 12, 2010, 08:20:55 PM
Sorry for the necro bump, but I would love a mod that does this in 1.1.11
i too would like a mod like this.    is this the only one, or is there anything that will work with 1.1.11?
Title: Re: Who Voted What?
Post by: miDnIghtEr20C on August 21, 2010, 09:48:07 PM
yay... i finally got this to work!   :D   awesome!    just one question.    is there a way to make it optional in the poll to be viewed by all?   that way some polls are hidden, and some are viewable, depending on what you pick?       

is that already talked about in this thread?   what page?    thanks guys.
Title: Re: Who Voted What?
Post by: Stigmartyr on September 17, 2010, 04:42:46 PM
Quote from: mghome59 on January 21, 2010, 09:45:25 AM
Hope it`s ok now. Uninstall previous, then delete it, upload this one.  Don`t forget to clean your cache (from forum root) and enable who voted what from 

    * Forum » Administration Center » Features and Options

Confirmed: this mod attached to the post above installed successfully in SMF RC2 via package manager without a hitch.  I am running a curve based theme, if that helps as well, meaning I didn't have to do any additional theme edits, though it said it would fail on my iPhone theme, who cares.  Who uses iPhones anymore :P
Title: Re: Who Voted What?
Post by: Søren Bjerg on December 13, 2010, 12:35:42 PM
Likely to nobody's surprise I once again didn't get any work done updating this modification, although I didn't exactly promise to do so either. Also, I see no opportunity in near to far future to set up a development environment, get the newest publicly available version of SMF, figure out how stuff works now and recreate the modification - much less when people have already fixed and improved the code... so I fall back on one of my previous posts:

Quote from: Søren Bjerg on July 12, 2009, 06:37:56 AM
[...] I'll happily give permission to someone else to take over the development of the modification.
Title: Re: Who Voted What?
Post by: Rasyr on January 30, 2011, 03:01:26 PM
Has this been updated for SMF 2.0 RC4?
Title: Re: Who Voted What?
Post by: HorTs on February 17, 2011, 11:33:35 AM
I wish some clever person would take this over.
Title: Re: Who Voted What?
Post by: HorTs on February 23, 2011, 05:49:40 AM
Has anyone got it working with RC5 yet?
Title: Re: Who Voted What?
Post by: rbeuker on February 23, 2011, 03:15:52 PM
I have got it working on a patched RC4 version--I'm not sure if it'd also work on RC5.

USE AT YOUR OWN RISK!!

Check the contents of the modification.xml file and find the section that changes the Display.template.php file.
Below's the code I've used:

  <file name="$themedir/Display.template.php">
    <operation>
      <search position="replace"><![CDATA[ // Show each option with its corresponding percentage bar.
foreach ($context['poll']['options'] as $option)
{
echo '
<dt class="middletext', $option['voted_this'] ? ' voted' : '', '">', $option['option'], '</dt>
<dd class="middletext statsbar', $option['voted_this'] ? ' voted' : '', '">';

if ($context['allow_poll_view'])
echo '
', $option['bar_ndt'], '
<span class="percentage">', $option['votes'], ' (', $option['percent'], '%)</span>';

echo '
</dd>';
}

]]></search>
      <add><![CDATA[ // Show each option with its corresponding percentage bar.
foreach ($context['poll']['options'] as $option)
{
if (!allowedTo('poll_view_voters') || $modSettings['whovotedwhatMode'] == 'disabled')
{
echo '
<dt class="middletext', $option['voted_this'] ? ' voted' : '', '">', $option['option'], '</dt>
<dd class="middletext statsbar', $option['voted_this'] ? ' voted' : '', '">';

if ($context['allow_poll_view'])
echo '
', $option['bar_ndt'], '
<span class="percentage">', $option['votes'], ' (', $option['percent'], '%)</span>';

echo '
</dd>';
}
else
{
switch ($modSettings['whovotedwhatMode'])
{
case 'select':
echo '
<dt class="middletext', $option['voted_this'] ? ' voted' : '', '">', $option['option'], '</dt>
<dd class="middletext statsbar">';
if ($context['allow_poll_view'])
{
echo '' . $option['bar'] . ' ' . $option['votes'] . ' (' . $option['percent'] . '%)' . ' ' . '<select id="jumpto" name="voters' . $option['ID_OPTION'] . '" onchange="if (this.selectedIndex > 0 &amp;&amp; this.options[this.selectedIndex].value) window.location.href = smf_scripturl + this.options[this.selectedIndex].value.substr(smf_scripturl.indexOf(\'?\') == -1 || this.options[this.selectedIndex].value.substr(0, 1) != \'?\' ? 0 : 1);" style="width: 150px;">';
if (!empty($context['poll']['options'][$option['ID_OPTION']]['voters']))
              {
                echo '
                    <option selected="selected" value="#">' . $txt['poll_view_voters_expand_to_view'] . '</option>
                    <option disabled="disabled" value="">----------------------</option>';
                foreach ($context['poll']['options'][$option['ID_OPTION']]['voters'] as $voter)
                {
                  echo '
                    <option value="?action=profile;u=' . $voter['ID_MEMBER'] . '"> => ' . $voter['realName'] . '</option>';
                }
                echo '
                    <option disabled="disabled" value="">----------------------</option>
                    <option disabled="disabled" value="">' . $txt['poll_view_voters_expanded_help1'] . '</option>
                    <option disabled="disabled" value="">' . $txt['poll_view_voters_expanded_help2'] . '</option>';
              }
              else
              {
                echo '
                    <option selected="selected" value="">----------------------</option>';
              }
              echo '
                  </select>';
}
else
{
echo '';
}
echo '</dd>';
break;
case 'table':
echo '
<dt class="middletext', $option['voted_this'] ? ' voted' : '', '">', $option['option'], '</dt>
<dd class="middletext statsbar">';
if ($context['allow_poll_view'])
{
echo '' . $option['bar'] . ' ' . $option['votes'] . ' (' . $option['percent'] . '%)<br />';
if (!empty($context['poll']['options'][$option['ID_OPTION']]['voters']))
              {
                foreach ($context['poll']['options'][$option['ID_OPTION']]['voters'] as $voter)
                {
                  echo '<small><a href="?action=profile;u=' . $voter['ID_MEMBER'] . '">', $voter['realName'], '</a></small> ';
                }
              }
}
else
{
echo '';
}
echo '</dd>';
break;
}
}
}

]]></add>
    </operation>
  </file>


In the package-info.xml file you can change "RC2" to your Forum version (RC3, RC4 or RC5).

I have not changed the wvwDB.php file.

Put all 3 files into a zip file and try installing it using the package manager.

Good luck! :)
Title: Re: Who Voted What?
Post by: HorTs on February 23, 2011, 04:52:32 PM
Thanks, that worked great for me on RC5.

I really appreciate your effort in helping me.
Title: Re: Who Voted What?
Post by: hcfwesker on March 05, 2011, 11:02:03 PM
I got over 40 MODs, and your fix installed perfectly on smf2 RC4, rbeuker!  thanx a bunch :)
Title: Re: Who Voted What?
Post by: rbeuker on March 09, 2011, 03:57:38 PM
you're welcome :)
Title: Re: Who Voted What?
Post by: edje12344 on March 16, 2011, 12:21:55 PM
I've don everythin Rbeuker wrote its installed but I don't find the names of the pollers.

What have I don wrong
Title: Re: Who Voted What?
Post by: Illori on March 16, 2011, 12:29:15 PM
did you enable the mod in the admin panel?
Title: Re: Who Voted What?
Post by: edje12344 on March 16, 2011, 12:36:30 PM
And how do I do that?  :o
Title: Re: Who Voted What?
Post by: Illori on March 16, 2011, 12:38:20 PM
features and options -> "Who Voted What? mode" as well as user group permissions to view who voted.
Title: Re: Who Voted What?
Post by: edje12344 on March 16, 2011, 02:50:24 PM
Standing on active:

Pollmodus ACTIVATED

Who Voted What? mode  TABLE VIEUW

Is it possible that de Dutch language does something wrong?
Title: Re: Who Voted What?
Post by: Illori on March 16, 2011, 03:06:36 PM
you need permissions set per group and if you have a custom theme you need to do the manual edits to the correct files to view the information
Title: Re: Who Voted What?
Post by: rbeuker on March 16, 2011, 05:05:57 PM
Quote from: edje12344 on March 16, 2011, 02:50:24 PM
Is it possible that de Dutch language does something wrong?
Het werkt prima met de Nederlandse taal :)
(It works fine with the Dutch language)
Title: Re: Who Voted What?
Post by: edje12344 on March 16, 2011, 05:24:39 PM
I see it's installed "everywhere" but I dont see find the names.
Title: Re: Who Voted What?
Post by: rbeuker on March 21, 2011, 04:33:25 PM
Quote from: edje12344 on March 16, 2011, 05:24:39 PM
I see it's installed "everywhere" but I dont see find the names.
Are you using the default SMF theme?
Title: Re: Who Voted What?
Post by: rufen on April 04, 2011, 03:37:37 PM
using default theme I only see ---------------- in the list view.

Title: Re: Who Voted What?
Post by: Casal on April 22, 2011, 05:36:03 PM
This mod doesn´t work in smf 2.0 Rc4.

Any suggestion for me??.I need help
Title: Re: Who Voted What?
Post by: ChaosEnergy on June 16, 2011, 05:06:33 PM
hope there will be an update for 2.0
Title: Re: Who Voted What?
Post by: Shorti25 on July 02, 2011, 03:22:07 PM
Quote from: ChaosEnergy on June 16, 2011, 05:06:33 PM
hope there will be an update for 2.0
i hope it too
Title: Re: Who Voted What?
Post by: lttung on July 14, 2011, 03:39:30 AM
Quote from: ChaosEnergy on June 16, 2011, 05:06:33 PM
hope there will be an update for 2.0

Good for me. SMF 2.0. Show voted user

http://custom.simplemachines.org/mods/index.php?mod=3003
Title: Re: Who Voted What?
Post by: hcfwesker on July 14, 2011, 04:51:09 PM
This does work on 2.0 ... just sayin. 

Emulate to RC4, and use the edits in this link  http://www.simplemachines.org/community/index.php?topic=110220.msg2965847#msg2965847

All you had to do was click 1 page back ;)
Title: Re: Who Voted What?
Post by: Khadamon on August 02, 2011, 08:15:22 AM
Any 2.0 version for this great Mod ?
Title: Re: Who Voted What?
Post by: Kindred on August 02, 2011, 10:24:48 AM
Quote from: hcfwesker on July 14, 2011, 04:51:09 PM
This does work on 2.0 ... just sayin. 

Emulate to RC4, and use the edits in this link  http://www.simplemachines.org/community/index.php?topic=110220.msg2965847#msg2965847

All you had to do was click 1 page back ;)
Title: Re: Who Voted What?
Post by: Khadamon on August 02, 2011, 10:30:08 AM
Well "use at you own risk", I would have prefer a proper pack in fact.

I guess I'll have to check and adapt.
Title: Re: Who Voted What?
Post by: HorTs on August 10, 2011, 07:52:54 AM
I've tried the mod amendment on the last page and all works but the percentage bar. Has anyone else manage to get this working with 2.0 final?
Title: Re: Who Voted What?
Post by: Illori on August 10, 2011, 08:19:35 AM
find

Code (display.template.php) Select

echo '' . $option['bar'] . ' ' . $option['votes'] . ' (' . $option['percent'] . '%)<br />';

Code (replace) Select

echo '' . $option['bar_ndt'] . ' ' . $option['votes'] . ' (' . $option['percent'] . '%)<br />';
Title: Re: Who Voted What?
Post by: Acer1 on November 27, 2011, 06:34:57 AM
This Mod for SMF 2.0.1 ????
Title: Re: Who Voted What?
Post by: H-J Kaabii on January 13, 2012, 02:17:52 AM
I was wondering (using relevant modifications to code to optimise for 2.0 Gold upwards) how I could incorporate the code from Display.template.php into the theme I'm using, Bright Forest. The theme's Display.template.php for some reason does not include if ($context['allow_poll_view'])
echo '
', $option['bar_ndt'], '
<span class="percentage">', $option['votes'], ' (', $option['percent'], '%)</span>';

but I'm unsure if this is because the theme calls up the default theme's code or for some other reason.
Title: Re: Who Voted What?
Post by: Sapozhnik on March 19, 2012, 05:52:15 PM
Quote from: rbeuker on February 23, 2011, 03:15:52 PM
I have got it working on a patched RC4 version--I'm not sure if it'd also work on RC5.

USE AT YOUR OWN RISK!!

Check the contents of the modification.xml file and find the section that changes the Display.template.php file.
Below's the code I've used:

  <file name="$themedir/Display.template.php">
    <operation>
      <search position="replace"><![CDATA[ // Show each option with its corresponding percentage bar.
foreach ($context['poll']['options'] as $option)
{
echo '
<dt class="middletext', $option['voted_this'] ? ' voted' : '', '">', $option['option'], '</dt>
<dd class="middletext statsbar', $option['voted_this'] ? ' voted' : '', '">';

if ($context['allow_poll_view'])
echo '
', $option['bar_ndt'], '
<span class="percentage">', $option['votes'], ' (', $option['percent'], '%)</span>';

echo '
</dd>';
}

]]></search>
      <add><![CDATA[ // Show each option with its corresponding percentage bar.
foreach ($context['poll']['options'] as $option)
{
if (!allowedTo('poll_view_voters') || $modSettings['whovotedwhatMode'] == 'disabled')
{
echo '
<dt class="middletext', $option['voted_this'] ? ' voted' : '', '">', $option['option'], '</dt>
<dd class="middletext statsbar', $option['voted_this'] ? ' voted' : '', '">';

if ($context['allow_poll_view'])
echo '
', $option['bar_ndt'], '
<span class="percentage">', $option['votes'], ' (', $option['percent'], '%)</span>';

echo '
</dd>';
}
else
{
switch ($modSettings['whovotedwhatMode'])
{
case 'select':
echo '
<dt class="middletext', $option['voted_this'] ? ' voted' : '', '">', $option['option'], '</dt>
<dd class="middletext statsbar">';
if ($context['allow_poll_view'])
{
echo '' . $option['bar'] . ' ' . $option['votes'] . ' (' . $option['percent'] . '%)' . ' ' . '<select id="jumpto" name="voters' . $option['ID_OPTION'] . '" onchange="if (this.selectedIndex > 0 &amp;&amp; this.options[this.selectedIndex].value) window.location.href = smf_scripturl + this.options[this.selectedIndex].value.substr(smf_scripturl.indexOf(\'?\') == -1 || this.options[this.selectedIndex].value.substr(0, 1) != \'?\' ? 0 : 1);" style="width: 150px;">';
if (!empty($context['poll']['options'][$option['ID_OPTION']]['voters']))
              {
                echo '
                    <option selected="selected" value="#">' . $txt['poll_view_voters_expand_to_view'] . '</option>
                    <option disabled="disabled" value="">----------------------</option>';
                foreach ($context['poll']['options'][$option['ID_OPTION']]['voters'] as $voter)
                {
                  echo '
                    <option value="?action=profile;u=' . $voter['ID_MEMBER'] . '"> => ' . $voter['realName'] . '</option>';
                }
                echo '
                    <option disabled="disabled" value="">----------------------</option>
                    <option disabled="disabled" value="">' . $txt['poll_view_voters_expanded_help1'] . '</option>
                    <option disabled="disabled" value="">' . $txt['poll_view_voters_expanded_help2'] . '</option>';
              }
              else
              {
                echo '
                    <option selected="selected" value="">----------------------</option>';
              }
              echo '
                  </select>';
}
else
{
echo '';
}
echo '</dd>';
break;
case 'table':
echo '
<dt class="middletext', $option['voted_this'] ? ' voted' : '', '">', $option['option'], '</dt>
<dd class="middletext statsbar">';
if ($context['allow_poll_view'])
{
echo '' . $option['bar'] . ' ' . $option['votes'] . ' (' . $option['percent'] . '%)<br />';
if (!empty($context['poll']['options'][$option['ID_OPTION']]['voters']))
              {
                foreach ($context['poll']['options'][$option['ID_OPTION']]['voters'] as $voter)
                {
                  echo '<small><a href="?action=profile;u=' . $voter['ID_MEMBER'] . '">', $voter['realName'], '</a></small> ';
                }
              }
}
else
{
echo '';
}
echo '</dd>';
break;
}
}
}

]]></add>
    </operation>
  </file>


In the package-info.xml file you can change "RC2" to your Forum version (RC3, RC4 or RC5).

I have not changed the wvwDB.php file.

Put all 3 files into a zip file and try installing it using the package manager.

Good luck! :)

Thanks a lot.
Package for SMF 2.0.2 is attached

Important!!!
     Activate: Features and options -> "Who Voted What? mode"
      Permission: Set permission for users group
Title: Re: Who Voted What?
Post by: Illori on March 19, 2012, 06:31:06 PM
this mod does not have a license so you are not allowed to update it without permission from the author. so your attachment has been removed.
Title: Re: Who Voted What?
Post by: Nibogo on March 19, 2012, 11:45:30 PM
2.0 mod:

http://custom.simplemachines.org/mods/index.php?mod=3003
Title: Re: Who Voted What?
Post by: Ray Cardillo on May 07, 2012, 06:30:44 PM
Quote from: Acer1 on November 27, 2011, 06:34:57 AM
This Mod for SMF 2.0.1 ????

FYI, since this one didn't offer it, I created another mod that was recently approved for release that provides several levels of visibility and allows you to configure required comments, etc.

http://custom.simplemachines.org/mods/index.php?mod=3373
Title: Re: Who Voted What?
Post by: CedarMill on April 18, 2014, 10:05:25 AM
Modification Who Voted What for SMF 2.0.7 (archive attached to the message) 8)
Title: Re: Who Voted What?
Post by: Illori on April 18, 2014, 02:10:30 PM
since the mod has no license you are not allowed to modify it and then attach the modified package anywhere, or distribute it.
Title: Re: Who Voted What?
Post by: lemur21 on February 24, 2016, 05:24:38 PM
Has this ever been updated for 2.0? This was a FANTASTIC mod (and, sadly, the others don't seem to have the same functionality).