Simple Machines Community Forum

Customizing SMF => Modifications and Packages => Topic started by: Windy on January 06, 2009, 08:12:57 AM

Title: Additional Polls
Post by: Windy on January 06, 2009, 08:12:57 AM
Link to Mod (http://custom.simplemachines.org/mods/index.php?mod=1586)

Additional Polls


Removes the restriction that prevents you from having more than one poll in a topic.
Title: Re: Additional Polls
Post by: shadow82x on January 06, 2009, 03:20:41 PM
This will be a very useful modification. Thanks! :D
Title: Re: Additional Polls
Post by: lakechurch on January 06, 2009, 03:57:47 PM
I installed the mod, it is very simple and works perfect, thanks!
Title: Re: Additional Polls
Post by: Nibogo on January 06, 2009, 05:53:42 PM
Awesome mod , thanks is a really good one
Title: Re: Additional Polls
Post by: Smitten on January 07, 2009, 01:59:00 AM
Excelent, but... if have the Who Voted What installed it doesn´t work.

Any idea? I give you my display.template

Thanks!!
Title: Re: Additional Polls
Post by: nosferatu on January 07, 2009, 02:02:33 PM
I'm afraid I can't see any difference. I am using a theme (BlueSkies) but it doesn't work in the SMF default theme either. It stated that it had been installed successfully so is there something else I should be looking at?

Actually I've now had to uninstall the theme as it interfered with a poll I was currently running. Where I had given an option to change a vote, after installing the mod, when a user attempted to change a cast vote, it was returning an error to the effect that the Board did not exist. Even when I as the admin tried to edit the poll, it came back with the same error. When I uninstalled the mod, the poll worked fine again.

Cheers

Nos
Title: Re: Additional Polls
Post by: gemigene on January 07, 2009, 04:03:30 PM
I installed this package and it fouled up my polls function when I uninstalled it, I lost my "remove poll" function.

The reason I uninstalled it was that I got the following error (error log) after making 1 test poll only (without making a 2nd poll):

2: mysql_free_result(): 370 is not a valid MySQL result resource
File: /home/mysite/public_html/forum/Packages/temp/code.php
Line: 61


And "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 '' at line 2 File: /home/mysite/public_html/forum/Sources/Poll.php Line: 773" when trying to edit a poll.

So, how do I restore my "remove poll" function?

Wonder if it should be reported as an unsafe Mod...

Gene
Title: Re: Additional Polls
Post by: nosferatu on January 07, 2009, 04:10:50 PM
Now that you say that, I've noticed my 'remove poll' option has also disappeared.
Title: Re: Additional Polls
Post by: gemigene on January 07, 2009, 04:17:28 PM
Quote from: nosferatu on January 07, 2009, 04:10:50 PM
Now that you say that, I've noticed my 'remove poll' option has also disappeared.

Hmm, that makes two of us, I sure hope the Mod author will come up with a solution...

Cheers,
Gene
Title: Re: Additional Polls
Post by: blondeamon on January 07, 2009, 08:00:33 PM
Everything works great here.

This is one of the most useful mods around , thanks man
Title: Re: Additional Polls
Post by: Windy on January 08, 2009, 06:41:28 AM
Fixed a minor installation bug that would cause the some pre-existing polls to not function properly when performing actions related to them.  Also made a few minor template changes to ensure greater compatibility with pre-existing mods.

Quote from: Smitten on January 07, 2009, 01:59:00 AM
Excelent, but... if have the Who Voted What installed it doesn´t work.

Any idea? I give you my display.template

Thanks!!
If you install the latest version with the changes I've made, when trying to install that mod over the top of mine it should report that all tests are successful (I tried this myself with just these two mods, so if you're getting any errors, this would be due to another mod), however it won't have installed properly and will fail to work as expected.  The solution is to make changes to that particular mod's modification.xml file located inside the zip file for it.  This is the change you will be required to make.
Code (Search) Select
<search position="after"><![CDATA[ }

// Calculate the fastest way to get the messages!
]]></search>

Code (Replace) Select
<search position="before"><![CDATA[ > 1 ? 'checkbox' : 'radio') . '" name="options[]" id="options-' . $i . '" value="' . $i . '" class="check" />'
);
}]]></search>

That mod will still be able to function stand alone with this change intact, so if you ever decide to uninstall my mod (you will be required to remove this one first) that package should still be able to install successfully.

Quote from: gemigene on January 07, 2009, 04:17:28 PM
Quote from: nosferatu on January 07, 2009, 04:10:50 PM
Now that you say that, I've noticed my 'remove poll' option has also disappeared.

Hmm, that makes two of us, I sure hope the Mod author will come up with a solution...

Cheers,
Gene
There is no solution, if you uninstall a package, you lose the changes it makes, simple as that.  As for the sql error, that's probably related to the error I fixed above, otherwise I can only assume that it's caused by conflicting with another mod. Also, please don't message me support related issues regarding mods, this is what these topics are for, trying to rush me will only irritate me and make me less likely to assist you.

Quote from: nosferatu on January 07, 2009, 02:02:33 PM
I'm afraid I can't see any difference. I am using a theme (BlueSkies) but it doesn't work in the SMF default theme either. It stated that it had been installed successfully so is there something else I should be looking at?

Actually I've now had to uninstall the theme as it interfered with a poll I was currently running. Where I had given an option to change a vote, after installing the mod, when a user attempted to change a cast vote, it was returning an error to the effect that the Board did not exist. Even when I as the admin tried to edit the poll, it came back with the same error. When I uninstalled the mod, the poll worked fine again.

Cheers

Nos
Again, probably related to the error I fixed above.  The difference you'll see when the mod is installed is rather minimal as it tries to keep template changes down to a minimum, or rather it doesn't need to make too many changes, effectively you'll only really notice it when you try to add a poll to a topic that already has one.
Title: Re: Additional Polls
Post by: [SiNaN] on January 08, 2009, 11:30:01 AM
Tested on a fresh SMF 1.1.7 forum and there doesn't seem to be any problems about removing polls.

Great mod Windy.
Title: Re: Additional Polls
Post by: gemigene on January 08, 2009, 01:08:20 PM
QuoteThere is no solution, if you uninstall a package, you lose the changes it makes, simple as that.  As for the sql error, that's probably related to the error I fixed above, otherwise I can only assume that it's caused by conflicting with another mod.

For some strange reason, if I create a new single poll and try to vote, I get the following error:
QuoteEither that poll doesn't exist, the poll has been locked, or you tried to vote twice.

I assume that there is a conflict with another mod.

Cheers,
Gene
Title: Re: Additional Polls
Post by: cubetgio on January 09, 2009, 05:38:44 AM
Hello windy,

Additional Polls v1.0
-----------------------------------
Removes the restriction that prevents you from having more than one poll in a topic.


How do i do this ?

Thanks you for this very usefull mod !
Title: Re: Additional Polls
Post by: nosferatu on January 10, 2009, 08:30:03 AM
If you look on the bottom bar below the messages, you'll see 'add poll'.

This appeared to work but, when I checked a test poll, I put 2 questions up and was able to answer the second one successfully, but when I attempted to vote on the first one it returned an error stating: Either that poll doesn't exist, the poll has been locked, or you tried to vote twice.

Why would it work on the second poll of 2 but not the first?
Title: Re: Additional Polls
Post by: Windy on January 10, 2009, 08:46:06 AM
Quote from: nosferatu on January 10, 2009, 08:30:03 AM
If you look on the bottom bar below the messages, you'll see 'add poll'.

This appeared to work but, when I checked a test poll, I put 2 questions up and was able to answer the second one successfully, but when I attempted to vote on the first one it returned an error stating: Either that poll doesn't exist, the poll has been locked, or you tried to vote twice.

Why would it work on the second poll of 2 but not the first?
What version are you using? as I don't experience any problems when voting, regardless of order.
Title: Re: Additional Polls
Post by: nosferatu on January 10, 2009, 01:02:10 PM
Thanks windy. I'm using the latest version, having deleted the initial and then uploading the new one. It doesn't interfere with the current poll I have (as was the case) so I can now remove my vote and vote again (referring to my original post on here). However, the added poll feature seems to throw up this strange error. It works fine and sets up the additional poll but, for some reason, allows voting on the second poll but not on the first. I do have some other mods installed so I can't rule out a conflict but it just seems a little strange.
Title: Re: Additional Polls
Post by: nosferatu on January 11, 2009, 06:26:21 AM
I unistalled the mod and attempted to reinstall but now get the following:

QuoteYou have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'WHERE ID_POLL = 10' at line 3
File: /home/southwalesuk/public_html/forum/Packages/temp/code.php
Line: 59

This hasn't affected my forum as it hasn't installed. Any ideas?
Title: Re: Additional Polls
Post by: Daggers on January 11, 2009, 06:46:27 AM
QuoteEither that poll doesn't exist, the poll has been locked, or you tried to vote twice.

I get this too ... uninstalled this one  :-\  :(
Title: Re: Additional Polls
Post by: Bancherd on January 11, 2009, 09:47:09 AM
Same problem here, got the same error message after trying to vote in the second poll.

I am using SMF1.1.7 which was upgraded from 1.1.5/1.1.4.  Database is utf-8(not that this should matter).

The mod was uninstalled without any problems, however.

Bancherd

Quote from: nosferatu on January 10, 2009, 08:30:03 AM
If you look on the bottom bar below the messages, you'll see 'add poll'.

This appeared to work but, when I checked a test poll, I put 2 questions up and was able to answer the second one successfully, but when I attempted to vote on the first one it returned an error stating: Either that poll doesn't exist, the poll has been locked, or you tried to vote twice.

Why would it work on the second poll of 2 but not the first?
Title: Re: Additional Polls
Post by: Windy on January 11, 2009, 09:56:15 AM
Quote from: nosferatu on January 11, 2009, 06:26:21 AM
I unistalled the mod and attempted to reinstall but now get the following:

QuoteYou have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'WHERE ID_POLL = 10' at line 3
File: /home/southwalesuk/public_html/forum/Packages/temp/code.php
Line: 59

This hasn't affected my forum as it hasn't installed. Any ideas?
I'd say that error might be due to the initial pre-existing polls issue that I fixed, where you've deleted a poll that existing before the mod was installed, but due to that the pre-existing poll issue, the poll wasn't properly removed from the database, therefore when the mod installs and tries to find that polls associated topic it won't find anything, causing that sql error.

I'll probably put the necessary code to delete those troublesome polls so that issue won't occur once we figure out what's causing this other issue.

QuoteEither that poll doesn't exist, the poll has been locked, or you tried to vote twice.
^^ As for those having that issue, I could really use some more information as I can't seem to replicate it.
the following would be quite useful
- version of the mod you're using
- whether the poll existed before you installed the mod
- using phpmyadmin or whatever other tool you've got access to view the databases tables and tell me what that poll has set for ID_TOPIC (you can get the poll id from one of the polls urls)
- giving me step by step actions of what you did and the changes reflected in the polls table in the database
- attach your poll.php so I can check for conflicts

the more information provided, the better I can debug the issue.
Title: Re: Additional Polls
Post by: LinK187 on January 12, 2009, 11:16:03 AM
Quote from: Windy on January 11, 2009, 09:56:15 AM
Quote from: nosferatu on January 11, 2009, 06:26:21 AM
I unistalled the mod and attempted to reinstall but now get the following:

QuoteYou have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'WHERE ID_POLL = 10' at line 3
File: /home/southwalesuk/public_html/forum/Packages/temp/code.php
Line: 59

This hasn't affected my forum as it hasn't installed. Any ideas?
I'd say that error might be due to the initial pre-existing polls issue that I fixed, where you've deleted a poll that existing before the mod was installed, but due to that the pre-existing poll issue, the poll wasn't properly removed from the database, therefore when the mod installs and tries to find that polls associated topic it won't find anything, causing that sql error.

I'll probably put the necessary code to delete those troublesome polls so that issue won't occur once we figure out what's causing this other issue.

QuoteEither that poll doesn't exist, the poll has been locked, or you tried to vote twice.
^^ As for those having that issue, I could really use some more information as I can't seem to replicate it.
the following would be quite useful
- version of the mod you're using
- whether the poll existed before you installed the mod
- using phpmyadmin or whatever other tool you've got access to view the databases tables and tell me what that poll has set for ID_TOPIC (you can get the poll id from one of the polls urls)
- giving me step by step actions of what you did and the changes reflected in the polls table in the database
- attach your poll.php so I can check for conflicts

the more information provided, the better I can debug the issue.

Ok:

SMF: 1.1.7
Your Mod: whatever was new 30 minutes ago

How to create the error:
-From a thread list when one clicks on "Post New Poll" it will take you to the post/poll creation page. After you post that poll is unvotable and produces the error: "Either that poll doesn't exist, the poll has been locked, or you tried to vote twice.". This only seems to effect polls created after the mod was installed.

However, if you are already viewing the thread and click "Add Poll", you can add as many polls as you want and they work great. However that thread starter poll is f00ked.

It's as if the creation of the poll is executed differently server side based on which you click.

However it is kinda of annoying that you have to create a thread first and then add the poll in order for it to work proper.

Edit: attached my poll.php
Title: Re: Additional Polls
Post by: Windy on January 12, 2009, 11:39:29 AM
Ok, I've been able to recreate the issue, it appears to be isolated to polls that are created through the "Post New Poll", I guess these polls are created differently, shouldn't be too difficult to fix.
Title: Re: Additional Polls
Post by: LinK187 on January 14, 2009, 11:36:05 AM
Quote from: Windy on January 12, 2009, 11:39:29 AM
Ok, I've been able to recreate the issue, it appears to be isolated to polls that are created through the "Post New Poll", I guess these polls are created differently, shouldn't be too difficult to fix.

Seeing as no fix has been posted yet, I'm assuming it's harder to fix than originally anticipated or the dev for this mod hasn't even seen my post yet.

As a short term fix, how would I disable the button "Post New Poll" ? That way I don't have to worry about users making botched polls until this mod is actually fixed.
Title: Re: Additional Polls
Post by: Windy on January 15, 2009, 08:40:06 AM
Quote from: LinK187 on January 14, 2009, 11:36:05 AM
Quote from: Windy on January 12, 2009, 11:39:29 AM
Ok, I've been able to recreate the issue, it appears to be isolated to polls that are created through the "Post New Poll", I guess these polls are created differently, shouldn't be too difficult to fix.

Seeing as no fix has been posted yet, I'm assuming it's harder to fix than originally anticipated or the dev for this mod hasn't even seen my post yet.

As a short term fix, how would I disable the button "Post New Poll" ? That way I don't have to worry about users making botched polls until this mod is actually fixed.
I did see your post, you led me to believe that it was an issue when using that particular method to create a poll :)

Open Post-Subs.php
Code (Find) Select

// Fix the message with the topic.
db_query("
UPDATE {$db_prefix}messages
SET ID_TOPIC = $topicOptions[id]
WHERE ID_MSG = $msgOptions[id]
LIMIT 1", __FILE__, __LINE__);


Code (Add Before or After that (Doesn't really matter)) Select

// Fix the message with the topic.
db_query("
UPDATE {$db_prefix}polls
SET ID_TOPIC = $topicOptions[id]
WHERE ID_POLL = $topicOptions[poll]
LIMIT 1", __FILE__, __LINE__);


Placing and running the code.php file located in the package from your smf root directory will fix up any of those polls that got botched.

I don't have time atm to properly implement the fixes into the package.  So if you can't wait then go ahead and do that.  I'd probably recommend just uninstalling it for the time being until I am able to get round to it.
Title: Re: Additional Polls
Post by: LinK187 on January 15, 2009, 10:06:35 AM
<remove this post>
Title: Re: Additional Polls
Post by: LinK187 on January 15, 2009, 11:12:37 AM
Quote from: Windy on January 15, 2009, 08:40:06 AM
Quote from: LinK187 on January 14, 2009, 11:36:05 AM
Quote from: Windy on January 12, 2009, 11:39:29 AM
Ok, I've been able to recreate the issue, it appears to be isolated to polls that are created through the "Post New Poll", I guess these polls are created differently, shouldn't be too difficult to fix.

Seeing as no fix has been posted yet, I'm assuming it's harder to fix than originally anticipated or the dev for this mod hasn't even seen my post yet.

As a short term fix, how would I disable the button "Post New Poll" ? That way I don't have to worry about users making botched polls until this mod is actually fixed.
I did see your post, you led me to believe that it was an issue when using that particular method to create a poll :)

Open Post-Subs.php
Code (Find) Select

// Fix the message with the topic.
db_query("
UPDATE {$db_prefix}messages
SET ID_TOPIC = $topicOptions[id]
WHERE ID_MSG = $msgOptions[id]
LIMIT 1", __FILE__, __LINE__);


Code (Add Before or After that (Doesn't really matter)) Select

// Fix the message with the topic.
db_query("
UPDATE {$db_prefix}polls
SET ID_TOPIC = $topicOptions[id]
WHERE ID_POLL = $topicOptions[poll]
LIMIT 1", __FILE__, __LINE__);


Placing and running the code.php file located in the package from your smf root directory will fix up any of those polls that got botched.

I don't have time atm to properly implement the fixes into the package.  So if you can't wait then go ahead and do that.  I'd probably recommend just uninstalling it for the time being until I am able to get round to it.

Ok this worked. However all threads started with a poll prior to this modification remain fu(ked, but all new threads started with a poll now work fine. Which is good enough.

btw it was Subs-Post.php and not Post-Subs.php which in fact, doesn't exist :P

Cheers
Title: Re: Additional Polls
Post by: LinK187 on January 15, 2009, 11:40:24 AM
Quote from: LinK187 on January 15, 2009, 11:12:37 AM
Quote from: Windy on January 15, 2009, 08:40:06 AM
Quote from: LinK187 on January 14, 2009, 11:36:05 AM
Quote from: Windy on January 12, 2009, 11:39:29 AM
Ok, I've been able to recreate the issue, it appears to be isolated to polls that are created through the "Post New Poll", I guess these polls are created differently, shouldn't be too difficult to fix.

Seeing as no fix has been posted yet, I'm assuming it's harder to fix than originally anticipated or the dev for this mod hasn't even seen my post yet.

As a short term fix, how would I disable the button "Post New Poll" ? That way I don't have to worry about users making botched polls until this mod is actually fixed.
I did see your post, you led me to believe that it was an issue when using that particular method to create a poll :)

Open Post-Subs.php
Code (Find) Select

// Fix the message with the topic.
db_query("
UPDATE {$db_prefix}messages
SET ID_TOPIC = $topicOptions[id]
WHERE ID_MSG = $msgOptions[id]
LIMIT 1", __FILE__, __LINE__);


Code (Add Before or After that (Doesn't really matter)) Select

// Fix the message with the topic.
db_query("
UPDATE {$db_prefix}polls
SET ID_TOPIC = $topicOptions[id]
WHERE ID_POLL = $topicOptions[poll]
LIMIT 1", __FILE__, __LINE__);


Placing and running the code.php file located in the package from your smf root directory will fix up any of those polls that got botched.

I don't have time atm to properly implement the fixes into the package.  So if you can't wait then go ahead and do that.  I'd probably recommend just uninstalling it for the time being until I am able to get round to it.

Ok this worked. However all threads started with a poll prior to this modification remain fu(ked, but all new threads started with a poll now work fine. Which is good enough.

btw it was Subs-Post.php and not Post-Subs.php which in fact, doesn't exist :P

Cheers

Ok, new problem. This modification has produced this error:
QuoteYou have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'LIMIT 1' at line 4
File: /home/****/public_html/forumtest/Sources/Subs-Post.php
Line: 1579

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

Line 1579 is the first line of the code you wanted me to add.

This error occurs when I tried to make a new thread. (regular post not poll).

I added the code before the "find" code. Would it make a diff if I moved it to after?
Title: Re: Additional Polls
Post by: mgrmgr on January 15, 2009, 11:43:29 AM
Quote from: Windy link=topic=284435.msg1879399#msg1879399

Open Post-Subs.php
...

Placing and running the code.php file located in the package from your smf root directory will fix up any of those polls that got botched.

I don't have time atm to properly implement the fixes into the package.  So if you can't wait then go ahead and do that.  I'd probably recommend just uninstalling it for the time being until I am able to get round to it.

Thank you so much :D

It's running ok now.

You are the bestest :) :-*
Title: Re: Additional Polls
Post by: LinK187 on January 15, 2009, 11:48:46 AM
Quote from: mgrmgr on January 15, 2009, 11:43:29 AM
Quote from: Windy link=topic=284435.msg1879399#msg1879399

Open Post-Subs.php
...

Placing and running the code.php file located in the package from your smf root directory will fix up any of those polls that got botched.

I don't have time atm to properly implement the fixes into the package.  So if you can't wait then go ahead and do that.  I'd probably recommend just uninstalling it for the time being until I am able to get round to it.

Thank you so much :D

It's running ok now.

You are the bestest :) :-*

try to make a regular post, you will get a sql database error... you can reply to existing threads but making a new thread produces the error.
Title: Re: Additional Polls
Post by: mgrmgr on January 15, 2009, 12:30:16 PM
oups - sorry! I forgot my own code change:


// Fix the poll with the topic.
if (!$topicOptions['poll'] === null)
    db_query("
UPDATE {$db_prefix}polls
SET ID_TOPIC = $topicOptions[id]
WHERE ID_POLL = $topicOptions[poll]
LIMIT 1", __FILE__, __LINE__);


Tested with create topic, reply to topic, create poll, reply to poll. Did I forget another test?

Once more: sorry
Title: Re: Additional Polls
Post by: LinK187 on January 15, 2009, 12:36:22 PM
Quote from: mgrmgr on January 15, 2009, 12:30:16 PM
oups - sorry! I forgot my own code change:


// Fix the poll with the topic.
if (!$topicOptions['poll'] === null)
   db_query("
UPDATE {$db_prefix}polls
SET ID_TOPIC = $topicOptions[id]
WHERE ID_POLL = $topicOptions[poll]
LIMIT 1", __FILE__, __LINE__);


Tested with create topic, reply to topic, create poll, reply to poll. Did I forget another test?

Once more: sorry

I'll test this when I get home, just on my way to work. So this code goes in the same place as specified above?
Title: Re: Additional Polls
Post by: mgrmgr on January 15, 2009, 01:14:55 PM
lol - that Post-Subs.php against the real Subs-Post.php did puzzle me at first too :)

and yep - it does work at both places - I set it after the found code (without real reason :) ) and added the additional comment on top of the code :) (Commenting code: a real nightmare for a programmer. Reminds me of a part out of my "Real Programmers" collection:

Real programmers don't comment their code! What was hard to write ought to be hard to understand :)
Title: Re: Additional Polls
Post by: LinK187 on January 15, 2009, 10:33:41 PM
Quote from: LinK187 on January 15, 2009, 12:36:22 PM
Quote from: mgrmgr on January 15, 2009, 12:30:16 PM
oups - sorry! I forgot my own code change:


// Fix the poll with the topic.
if (!$topicOptions['poll'] === null)
    db_query("
UPDATE {$db_prefix}polls
SET ID_TOPIC = $topicOptions[id]
WHERE ID_POLL = $topicOptions[poll]
LIMIT 1", __FILE__, __LINE__);


Tested with create topic, reply to topic, create poll, reply to poll. Did I forget another test?

Once more: sorry

I'll test this when I get home, just on my way to work. So this code goes in the same place as specified above?

this code brings back the original problem of the "post new poll" butting fu(king up the thread starter poll. additional polls added to the thread work fine. Except additional polls are added on top of the original instead of the bottom, which really makes no diff in functionality. However, it does fix the posting of a regular new thread.

I'm rolling back again while I wait for a proper fix.
Title: Re: Additional Polls
Post by: KahneFan on January 16, 2009, 12:18:12 PM
Gotta ask: Any thoughts on making this 2.0b4 compatible?
Title: Re: Additional Polls
Post by: Windy on January 16, 2009, 10:38:09 PM
Ok, new version fixing that particular issue, as well as a few others has released as version 1.0.2.

Quote from: KahneFan on January 16, 2009, 12:18:12 PM
Gotta ask: Any thoughts on making this 2.0b4 compatible?
A this particular time, no, as it would essentially require a complete rewrite.  As there maybe more issues or the possibility for more features to be discovered here, I feel that for the time being I could only really support one version of this mod at this time.
Title: Re: Additional Polls
Post by: LinK187 on January 16, 2009, 10:55:14 PM
Quote from: Windy on January 16, 2009, 10:38:09 PM
Ok, new version fixing that particular issue, as well as a few others has released as version 1.0.2.

Quote from: KahneFan on January 16, 2009, 12:18:12 PM
Gotta ask: Any thoughts on making this 2.0b4 compatible?
A this particular time, no, as it would essentially require a complete rewrite.  As there maybe more issues or the possibility for more features to be discovered here, I feel that for the time being I could only really support one version of this mod at this time.

PROPA BO I TELL THEE WHAT!

it fu(kin works without a hitch! cheers! :)
Title: Re: Additional Polls
Post by: nosferatu on January 17, 2009, 07:04:22 AM
Windy, this appears to work fine now. Thanks very much for your hard work and perseverance. Much appreciated.  O:)
Title: Re: Additional Polls
Post by: Bancherd on January 17, 2009, 07:17:54 AM
Thanks for the update.  Working great!
Title: Re: Additional Polls
Post by: !Hachi! on January 19, 2009, 10:29:49 AM
i installed both mod this and who voted what.but i can't see user names who voted in poll.in table view its missing and in select box no name just ----- this option.but when i install only who voted what it shows fine.
tried on 1.1.7 with no other mod.any thoughts/
Title: Re: Additional Polls
Post by: Windy on January 19, 2009, 10:36:22 AM
Quote from: Hassan on January 19, 2009, 10:29:49 AM
i installed both mod this and who voted what.but i can't see user names who voted in poll.in table view its missing and in select box no name just ----- this option.but when i install only who voted what it shows fine.
tried on 1.1.7 with no other mod.any thoughts/
http://www.simplemachines.org/community/index.php?topic=284435.msg1869988#msg1869988
Title: Re: Additional Polls
Post by: !Hachi! on January 19, 2009, 11:01:41 PM
i installed both mods with no errors but i can't see username showing up under polls option.
screenshot attached
Title: Re: Additional Polls
Post by: sreisenb001 on January 27, 2009, 04:33:48 PM
I installed on my new test forum.. it looks the same as the regular SMF poll..What am i doing wrong not to see the additonal polls
Title: Re: Additional Polls
Post by: LinK187 on January 27, 2009, 08:55:51 PM
Quote from: sreisenb001 on January 27, 2009, 04:33:48 PM
I installed on my new test forum.. it looks the same as the regular SMF poll..What am i doing wrong not to see the additonal polls

You can now click on add poll while viewing the thread. Add as many polls as you want. Hence the point of the mod.
Title: Re: Additional Polls
Post by: chinaren on February 02, 2009, 01:47:04 AM
Cool!  Thanks for this Mod, I've been wanting something like this for some time now.

Anyway, (so far) it's working well on my forum! 

(http://tomecity.com/smf/gallery/54_18_01_09_7_54_56.gif)
Title: Re: Additional Polls
Post by: diamanda on February 05, 2009, 02:24:19 PM
I need this mod in spanish, please :(
Title: Re: Additional Polls
Post by: Windy on February 06, 2009, 08:06:06 AM
Quote from: Peranbury on February 05, 2009, 02:24:19 PM
I need this mod in spanish, please :(

This mod doesn't include any language additions to smf, so if a spanish translation of smf exists then it should work just fine with it.
Title: Re: Additional Polls
Post by: PaulThePhotographer on February 14, 2009, 06:32:08 AM
I am having some issues with 1.0.1 also with the

"An Error Has Occurred!
Either that poll doesn't exist, the poll has been locked, or you tried to vote twice."


I wanted to uninstall and then install the latest version, 1.0.2 but;

There is NO uninstaller listed in the "Browse Packages" page, and even when I went to the "INSTALLED PACKAGES" page and clicked 'Uninstall" I get

"An Error Has Occurred!
This package cannot be uninstalled, because there is no uninstaller!

Please contact the mod author for more information."


How do I uninstall 1.0.1

Thanks, very useful mod also.
Title: Re: Additional Polls
Post by: !Hachi! on February 20, 2009, 08:10:12 AM
anyone using additional poll mod and who voted what? under one forum?
Title: Re: Additional Polls
Post by: Eddy Matthews on February 27, 2009, 01:51:19 PM
The mod won't install with SMF 1.1.8 - Is there a newer release that will work?

Or failing that, is it safe to simply edit the package-info.xml file so that it will install?

Regards
Eddy
Title: Re: Additional Polls
Post by: Eddy Matthews on February 28, 2009, 05:27:06 AM
Quote from: Eddy Matthews on February 27, 2009, 01:51:19 PM
The mod won't install with SMF 1.1.8 - Is there a newer release that will work?

Or failing that, is it safe to simply edit the package-info.xml file so that it will install?

Regards
Eddy

BUMP!

Can anyone help please?

Regards
Eddy
Title: Re: Additional Polls
Post by: !Hachi! on February 28, 2009, 05:31:49 AM
its safe to edit .xml file and  use with 1.1.8.
Title: Re: Additional Polls
Post by: Eddy Matthews on February 28, 2009, 05:34:35 AM
Quote from: !Hachi! on February 28, 2009, 05:31:49 AM
its safe to edit .xml file and  use with 1.1.8.

Thankyou, much appreciated...

Regards
Eddy
Title: Re: Additional Polls
Post by: gameballa on March 09, 2009, 05:11:08 PM
it would be great to allow the polls to be collapsed??
Title: Re: Additional Polls
Post by: Bancherd on March 09, 2009, 09:29:30 PM
Quote from: Windy on January 16, 2009, 10:38:09 PM
Ok, new version fixing that particular issue, as well as a few others has released as version 1.0.2.

Quote from: KahneFan on January 16, 2009, 12:18:12 PM
Gotta ask: Any thoughts on making this 2.0b4 compatible?
A this particular time, no, as it would essentially require a complete rewrite.  As there maybe more issues or the possibility for more features to be discovered here, I feel that for the time being I could only really support one version of this mod at this time.

Current version( for 1.1.7/1.1.8  ) seems to be stable and it's a big hit for my users. :)  Now that we are on smf2RC1, any thoughts on updating this for smf2?
Title: Re: Additional Polls
Post by: B16Enk on March 29, 2009, 03:13:20 PM
 :)
Great Mod, just finished getting it installed on a 1.1.8 install with multiple themes converted to support it.

If anyone needs it I have Display.template.php files for:
Title: Re: Additional Polls
Post by: Petee on April 07, 2009, 10:04:00 PM
I got both the Who Voted What mod and the Additional Polls mods installed on 1.1.8 with the changes suggested earlier. However, the list of "who voted what" all appear on the same line. For example:

Poll 1:
Option A: I voted
Option B:

Poll 2:
Option A: I voted
Option B:

Poll 3
Option A:
Option B: I voted

When looking at who voted:

Poll 1:
Option A:
me
Option B:

Poll 2:
Option A:
me
Optoin B:

Poll 3:
Option A:
me
Option B:

Even tho I chose Option B on the 3rd poll, I show under Option A with Option B in bold. Everyone that votes after me, is put in-line after my name, regardless of which option they choose.
Title: Re: Additional Polls
Post by: gameballa on April 08, 2009, 10:05:07 AM
Quote from: Petee on April 07, 2009, 10:04:00 PM
I got both the Who Voted What mod and the Additional Polls mods installed on 1.1.8 with the changes suggested earlier. However, the list of "who voted what" all appear on the same line. For example:

Poll 1:
Option A: I voted
Option B:

Poll 2:
Option A: I voted
Option B:

Poll 3
Option A:
Option B: I voted

When looking at who voted:

Poll 1:
Option A:
me
Option B:

Poll 2:
Option A:
me
Optoin B:

Poll 3:
Option A:
me
Option B:

Even tho I chose Option B on the 3rd poll, I show under Option A with Option B in bold. Everyone that votes after me, is put in-line after my name, regardless of which option they choose.

Yup this happends to me to.. Its worthless having these 2 mods turned on in 1.1.8 without some sort of fix!! Please help us who do not know php well enough to fix this problem ourselves!!
Title: Re: Additional Polls
Post by: timned88 on April 16, 2009, 11:34:55 PM
can this be updated for 2.0 rc1, please?
Title: Re: Additional Polls
Post by: Gwydion Frost on May 01, 2009, 09:57:09 PM
Windy, this mod combined with the Who Voted What mod are an AWESOME combination, when you apply the fix you suggested. PERFECTION!




Spoke too soon. Yeah, I'm getting the same glitch as the two above... the voters aren't lining up with the votes. Hrmmm...
Title: Re: Additional Polls
Post by: Windy on May 25, 2009, 10:19:59 AM
Version Bump.
Perhaps I might suggest that in the operation where I've suggested the fix, that in the addition code bit, replace $topicinfo with $poll and see how that goes.
Title: Re: Additional Polls
Post by: goforit on July 18, 2009, 07:06:14 PM
When i tried to install this mod on my 1.1.9...and again on my 1.1.10 version forum, i get this error message: The package you are trying to download or install is either corrupt or not compatible with this version of SMF.

Any help please
Title: Re: Additional Polls
Post by: DocPixel on September 07, 2009, 01:45:30 AM
I'm planning to install this mod on my 1.1.10, provided it's compatible. Has anyone see issues with that?
Title: Re: Additional Polls
Post by: Windy on September 07, 2009, 05:31:35 AM
I don't believe there should be any issues with 1.1.10 provided you use the version emulate function of smf so you don't run into it saying that it's incompatible.
Title: Re: Additional Polls
Post by: DocPixel on September 07, 2009, 11:01:42 AM
Thanks, Windy. Can you point me toward how to use the emulate function? It's been a couple of years since I used it.

Also, are you planning an upgrade to this mod soon?
Title: Re: Additional Polls
Post by: Paracelsus on September 16, 2009, 04:55:49 AM
Windy,

Your MOD seems to work fine. I just had to make some adjustments in Display.template.php in order to work with "Who Voted What" Mod.

Something I miss is a Button "Vote All" or something like that that would allow to choose all options in every poll and then submit them at the same time (instead of pressing "vote" for each poll). Is there some small piece of code we can add for this micro-feature?
Title: Re: Additional Polls
Post by: Windy on September 16, 2009, 12:29:30 PM
That would require a fair amount of work as smf is still only designed to handle one poll at a time.
Title: Re: Additional Polls
Post by: Paracelsus on September 16, 2009, 02:04:55 PM
Quote from: Windy on September 16, 2009, 12:29:30 PM
That would require a fair amount of work as smf is still only designed to handle one poll at a time.

Hmmm... ok, no sweat, I'm sure people can manage clicking a few more times. ;)
Title: Re: Additional Polls
Post by: Alpay on September 17, 2009, 04:09:11 AM
hi;
do you thinkin adaptation for modification on SMF version 2.0 RC1.2 ?
Title: Re: Additional Polls
Post by: ttuu on September 22, 2009, 05:40:23 AM
Quote from: Paracelsus on September 16, 2009, 04:55:49 AM
Windy,

Your MOD seems to work fine. I just had to make some adjustments in Display.template.php in order to work with "Who Voted What" Mod.

Something I miss is a Button "Vote All" or something like that that would allow to choose all options in every poll and then submit them at the same time (instead of pressing "vote" for each poll). Is there some small piece of code we can add for this micro-feature?

i want this feature.
Title: Re: Additional Polls
Post by: GPM on November 07, 2009, 08:37:33 AM
Hi there,

Trying to install this on version 1.1.10, but also getting the message "The package you are trying to download or install is either corrupt or not compatible with this version of SMF."

Any way of correcting this? As far as i can see, the chance to 'emulate' is only available in SMF2
Title: Re: Additional Polls
Post by: GPM on November 07, 2009, 02:09:48 PM
Edited the xml to get this working, but now got a fresh problem. on the theme i'm using, the polls don't display at all, the box is empty where the poll usually shows up
Title: Re: Additional Polls
Post by: Windy on November 10, 2009, 07:58:25 AM
Quote from: GPM on November 07, 2009, 02:09:48 PM
Edited the xml to get this working, but now got a fresh problem. on the theme i'm using, the polls don't display at all, the box is empty where the poll usually shows up
You're going to have to provide more information, the issue would either be with the display.template.php or if you have changed something in display.php, you may want to attach your display.template.php file so I can take a look at it.

I've added a new version which bumps up the version for 1.1.10 and adds support for 2.0 RC2.  I've marked this as a beta release until I can be sure there aren't new bugs present, I've done some basic testing and it seems ok, but I'd rather see how it does in the wild so to speak as just about everything had to be changed in order to get it to work.
Title: Re: Additional Polls
Post by: GPM on November 13, 2009, 12:56:42 PM
Thanks. After enabling the mod, any existing polls in the 'slickprographite' theme vanish, with only the border of the poll showing up.

Also the 'add poll' button when already in a poll doesn't appear...
Title: Re: Additional Polls
Post by: Windy on November 14, 2009, 07:24:43 AM
It doesn't look like that Display.template.php file has been modified, did you get any errors during the installation?
Title: Re: Additional Polls
Post by: GPM on November 16, 2009, 12:09:34 PM
No errors at all, confirmed installation afterwards too
Title: Re: Additional Polls
Post by: Windy on November 16, 2009, 02:43:50 PM
Does this only happen in the 'slickprographite', does it look fine in the default theme?
Title: Re: Additional Polls
Post by: GPM on November 17, 2009, 04:53:43 AM
yeah, everything looks fine in the basic theme
Title: Uninstall mod: now Error in exisiting poll
Post by: jagular on November 17, 2009, 06:28:29 AM
Using smf version: SMF 1.1.10

Installed the mod - no problems.  Upon uninstalling the mod after no seeing no additional 2 poll function I uninstalled, but now receiving this message "Unable to load the 'main' template" on polls and all other posts.  When attempting to "reapply" the mod, i see this:

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

Any help would be greatly appreciated Windy...thanks.
Title: Re: Additional Polls
Post by: jagular on November 17, 2009, 07:03:23 AM
Quote from: jagular on November 17, 2009, 06:28:29 AM
Using smf version: SMF 1.1.10

Installed the mod - no problems.  Upon uninstalling the mod after no seeing no additional 2 poll function I uninstalled, but now receiving this message "Unable to load the 'main' template" on polls and all other posts.  When attempting to "reapply" the mod, i see this:

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

Any help would be greatly appreciated Windy...thanks.

Update: the uninstall apparently destroyed the contents of the  "./Themes/default/Display.template.php " file.  I replaced it with the original SMF file and all appears to be fine now.
Title: Re: Additional Polls
Post by: Windy on November 17, 2009, 11:32:08 AM
Quote from: GPM on November 17, 2009, 04:53:43 AM
yeah, everything looks fine in the basic theme
It probably means then that you'll have to do a manual install for that theme.

Manual Installation of Mods (http://docs.simplemachines.org/index.php?topic=402.0)
Title: Re: Additional Polls
Post by: Xarcell on November 24, 2009, 06:25:10 PM
In 2.0 RC2 is there not a way to trim back some of the duplicate material with the polls? Perhaps at least have only one "poll" catbg? Or have the polls in the same container?

In previous versions of SMF it doesn't look that bad, but in 2.0 RC2 it's kinda ruined. It looks ghetto...

Title: Re: Additional Polls
Post by: Windy on November 25, 2009, 05:11:37 PM
Quote from: Xarcell on November 24, 2009, 06:25:10 PM
In 2.0 RC2 is there not a way to trim back some of the duplicate material with the polls? Perhaps at least have only one "poll" catbg? Or have the polls in the same container?

In previous versions of SMF it doesn't look that bad, but in 2.0 RC2 it's kinda ruined. It looks ghetto...


Well the reason I did that is because the buttons to modify the polls, which where previously located inside the container, are now located on the outside.
Title: Re: Additional Polls
Post by: shumilica on December 08, 2009, 11:30:10 AM
It doesn't work for me in RC2... install succesfull but it doesn't show any new option and in the current active polls i can't see anymore the question, answers, voting results. It's just the table where the poll should have been. If i uninstall, polls come to life again.

These are the mods I allready have installed:

1. Yet Another Global Announcements Mod 2.3 [ Uninstall ]
2. TextSizer 1.5 [ Uninstall ]
3. PM Attachments 1.4 [ Uninstall ]
4. Ad Managment 2.3.6 [ Uninstall ]
5. Favourite (Favorite) Boards 1.1 [ Uninstall ]
6. SimpleSEF 1.0.1 [ Uninstall ]
7. Save PM as HTML 1.0.7 [ Uninstall ]
8. Display Signatures Only Once Per Page 1.0.3 [ Uninstall ]
9. Read Sticky Topics 1.0.0 [ Uninstall ]
10. Topic Count in Profile 1.5 [ Uninstall ]
11. Profile Fields & Icons Mod 1.0 [ Uninstall ]
Title: Re: Additional Polls
Post by: Windy on December 08, 2009, 11:57:53 PM
Quote from: shumilica on December 08, 2009, 11:30:10 AM
It doesn't work for me in RC2... install succesfull but it doesn't show any new option and in the current active polls i can't see anymore the question, answers, voting results. It's just the table where the poll should have been. If i uninstall, polls come to life again.

These are the mods I allready have installed:

1. Yet Another Global Announcements Mod 2.3 [ Uninstall ]
2. TextSizer 1.5 [ Uninstall ]
3. PM Attachments 1.4 [ Uninstall ]
4. Ad Managment 2.3.6 [ Uninstall ]
5. Favourite (Favorite) Boards 1.1 [ Uninstall ]
6. SimpleSEF 1.0.1 [ Uninstall ]
7. Save PM as HTML 1.0.7 [ Uninstall ]
8. Display Signatures Only Once Per Page 1.0.3 [ Uninstall ]
9. Read Sticky Topics 1.0.0 [ Uninstall ]
10. Topic Count in Profile 1.5 [ Uninstall ]
11. Profile Fields & Icons Mod 1.0 [ Uninstall ]

It's most likely that the theme your using has a custom display template and you'll need to follow Manual Installation of Mods (http://docs.simplemachines.org/index.php?topic=402.0)
Title: Re: Additional Polls
Post by: shumilica on December 09, 2009, 01:51:18 PM
I use the default (curve) theme, and the installation said successful, even in display.template...
Title: Re: Additional Polls
Post by: Windy on December 09, 2009, 02:17:39 PM
well then attach your display template and i'll take a look at it
Title: Re: Additional Polls
Post by: shumilica on December 09, 2009, 05:13:59 PM
I found what caused the problem. This mod is not compatible with "Display Signatures Only Once Per Page 1.0.3" mod. After uninstalling that mod, this mod works well.
But one functionality question:
when somebody wants to add a new poll with new topic, he has to put first only the first question, publish the topic, then hit 'add poll' again for the next question? this is the default behavior? If yes, it definitely reduces the usefulness of this mod.
It would be better to be able to add more questions from the posting new poll window, where you post a new topic+a poll. No?
Title: Re: Additional Polls
Post by: DocPixel on December 21, 2009, 01:21:59 AM
I just finished reading through the whole thread, and can't find a solution. I installed version 1_1b on smf 1.1.10, and it reported that it installed correctly. My mod list also shows it as installed.

However, I don't see any button to add an additional poll, anywhere.  It looks just like it did before. Where's the button hiding? I tried it in the default theme and it doesn't work there either.
Thanks.
Title: Re: Additional Polls
Post by: Xarcell on December 21, 2009, 07:50:13 PM
Quote from: DocPixel on December 21, 2009, 01:21:59 AM
I just finished reading through the whole thread, and can't find a solution. I installed version 1_1b on smf 1.1.10, and it reported that it installed correctly. My mod list also shows it as installed.

However, I don't see any button to add an additional poll, anywhere.  It looks just like it did before. Where's the button hiding? I tried it in the default theme and it doesn't work there either.
Thanks.

The button isn't hiding. Create a topic, then add poll, then add poll again, etc...
Title: Re: Additional Polls
Post by: DocPixel on December 21, 2009, 08:53:18 PM
That sounds logical, Xarcell. I created a topic and added the first poll. Am I just not seeing the button?
Title: Re: Additional Polls
Post by: Xarcell on December 22, 2009, 01:35:22 AM
Try it with the default theme
Title: Re: Additional Polls
Post by: DocPixel on December 22, 2009, 01:23:10 PM
I did that already.  ;)
Title: Re: Additional Polls
Post by: DocPixel on December 23, 2009, 12:50:33 AM
I'm still trying to find out where the "add poll" button would be if this was working correctly. Anyone got a screen shot that shows it?  :)
Title: Re: Additional Polls
Post by: Xarcell on December 26, 2009, 09:58:23 PM
It's supposed to be right beside the "reply" button.
Title: Re: Additional Polls
Post by: DocPixel on December 27, 2009, 06:33:47 PM
Thanks, Xarcell. It's not showing.  :P
Title: Re: Additional Polls
Post by: Xarcell on December 28, 2009, 05:17:08 AM
I would go through and check the code manually to make sure it installed properly...
Title: Re: Additional Polls
Post by: DocPixel on December 28, 2009, 12:07:23 PM
Quote from: Xarcell on December 28, 2009, 05:17:08 AM
I would go through and check the code manually to make sure it installed properly...

Which file, which code and what would I be looking for?
Title: Re: Additional Polls
Post by: C4G-TK on January 11, 2010, 02:41:36 PM
I've installed this the other day and have had made a few multi-poll posts to try it out.  I just wanted to say that this has been a great addition to the site.

Great Job!

Using it on RC2 w/ Curve and Prince Of Darkness themes
Title: Re: Additional Polls
Post by: C4G-TK on January 16, 2010, 09:02:19 PM
OK, two slight things that I am noticing.

1)
If I use more than one poll per topic the following shows up under maintenance in Admin Panel.

I went into Admin Panel and into Maintenance.  Then, I selected ROUTINE and  Find and repair any errors   All of the secondary polls that were added show up as errors when you do this and say that they do not associate with any thread/post.

I hit repair to see what would happen and they then get severed from the thread that they appear in and go to a salvage area by themselves.





2)
Also, I just noticed this error when I split a topic.

Attached a pic of error.  The line involved has to do with polls, so I'm assuming that it may have to do with this mod since it is the only mod I have installed that made any changes to the SplitTopics.php file.

BTW, there was no poll attached to this thread.
Title: Re: Additional Polls
Post by: Windy on January 18, 2010, 03:03:28 AM
The first issue can be fixed by adding
if(!empty($_POST['polls']))
above the foreach statement in SplitTopics.php.

The following should fix the issues with maintenance in RepairBoards.php.
Code (Search) Select
(t.id_poll = p.id_poll)
Code (Replace) Select
(t.id_topic = p.id_topic)
Code (Search) Select
AND t.id_poll IS NULL
Code (Replace) Select
AND p.id_topic IS NULL

I haven't tested this though, I imagine these issues would also be present in the 1.1.x version as well, I'll be sure to fix them in the next update.
Title: Re: Additional Polls
Post by: C4G-TK on January 18, 2010, 10:11:01 PM
Quote from: Windy on January 18, 2010, 03:03:28 AM
The first issue can be fixed by adding
if(!empty($_POST['polls']))
above the foreach statement in SplitTopics.php.

Is that before the foreach statement in edit #3 or edit #4? (or both)  There are two foreach statements.

Title: Re: Additional Polls
Post by: Windy on January 20, 2010, 06:49:47 AM
Quote from: C4G-TK on January 18, 2010, 10:11:01 PM
Quote from: Windy on January 18, 2010, 03:03:28 AM
The first issue can be fixed by adding
if(!empty($_POST['polls']))
above the foreach statement in SplitTopics.php.

Is that before the foreach statement in edit #3 or edit #4? (or both)  There are two foreach statements.


before the one that's giving you the error.
Title: Re: Additional Polls
Post by: C4G-TK on January 20, 2010, 12:10:58 PM
ohhh duh!   ??? :o ;D

Thanks again!

Title: Re: Additional Polls
Post by: GPM on February 01, 2010, 02:44:12 PM
Hi there Windy.

Manually changed the display template for the 'slickpro-graphite' theme, and the default split topic file, but when i post a thread, all i see is the 'poll' box, with no actual poll displayed in it, and no options whatsoever....

Any idea what's up?
Title: Re: Additional Polls
Post by: Windy on February 01, 2010, 05:40:42 PM
hmm, from what I can see you've made the changes correctly, how does it look on the default theme? did you run into any errors when installing?
Title: Re: Additional Polls
Post by: OFoldfart on February 04, 2010, 12:30:23 AM
Sounds like it will be a great mod. Are you going to upgrade it for 1.1.11

Title: Re: Additional Polls
Post by: GPM on February 04, 2010, 06:53:12 PM
Quote from: Windy on February 01, 2010, 05:40:42 PM
hmm, from what I can see you've made the changes correctly, how does it look on the default theme? did you run into any errors when installing?

The poll is visable in default, though no option to add another poll is there

I've attatched an image of how my custom theme looks...
Title: Re: Additional Polls
Post by: GPM on February 14, 2010, 03:49:51 AM
Any ideas on this?  :(
Title: Re: Additional Polls
Post by: Windy on February 14, 2010, 01:55:12 PM
No clue, unless you modified the templates for the wrong theme or the files didn't upload properly when you did the changes.
Title: Re: Additional Polls
Post by: GPM on February 14, 2010, 04:34:07 PM
tried to download and reinstall, now get the message : 'not compatible with this version of SMF'

I'm running version 1.1.11
Title: Re: Additional Polls
Post by: Xarcell on February 23, 2010, 08:54:50 PM
Quote from: Windy on November 25, 2009, 05:11:37 PM
Quote from: Xarcell on November 24, 2009, 06:25:10 PM
In 2.0 RC2 is there not a way to trim back some of the duplicate material with the polls? Perhaps at least have only one "poll" catbg? Or have the polls in the same container?

In previous versions of SMF it doesn't look that bad, but in 2.0 RC2 it's kinda ruined. It looks ghetto...


Well the reason I did that is because the buttons to modify the polls, which where previously located inside the container, are now located on the outside.

Would it take alot of work to mod it to place the buttons on the outside of the container? Would it be ok for me to hire someone to change it?
Title: Re: Additional Polls
Post by: Windy on February 24, 2010, 08:19:04 AM
Quote from: Xarcell on February 23, 2010, 08:54:50 PM
Quote from: Windy on November 25, 2009, 05:11:37 PM
Quote from: Xarcell on November 24, 2009, 06:25:10 PM
In 2.0 RC2 is there not a way to trim back some of the duplicate material with the polls? Perhaps at least have only one "poll" catbg? Or have the polls in the same container?

In previous versions of SMF it doesn't look that bad, but in 2.0 RC2 it's kinda ruined. It looks ghetto...


Well the reason I did that is because the buttons to modify the polls, which where previously located inside the container, are now located on the outside.

Would it take alot of work to mod it to place the buttons on the outside of the container? Would it be ok for me to hire someone to change it?
I presume you mean inside of the container, as the buttons are already on the outside, which is causing the porblem, I would say overly it's rather easy assuming you know what you're doing, it just won't fit in with the existing curve style.
Title: Re: Additional Polls
Post by: Xarcell on February 24, 2010, 09:00:57 AM
Quote from: Windy on February 24, 2010, 08:19:04 AM
Quote from: Xarcell on February 23, 2010, 08:54:50 PM
Quote from: Windy on November 25, 2009, 05:11:37 PM
Quote from: Xarcell on November 24, 2009, 06:25:10 PM
In 2.0 RC2 is there not a way to trim back some of the duplicate material with the polls? Perhaps at least have only one "poll" catbg? Or have the polls in the same container?

In previous versions of SMF it doesn't look that bad, but in 2.0 RC2 it's kinda ruined. It looks ghetto...


Well the reason I did that is because the buttons to modify the polls, which where previously located inside the container, are now located on the outside.

Would it take alot of work to mod it to place the buttons on the outside of the container? Would it be ok for me to hire someone to change it?
I presume you mean inside of the container, as the buttons are already on the outside, which is causing the porblem, I would say overly it's rather easy assuming you know what you're doing, it just won't fit in with the existing curve style.

Do I have your permission to hire someone to try and alter it and make it show only one set of buttons? I would use it for my own private use, but can give it to you afterwards if necessary if you want to allow the public to use it.
Title: Re: Additional Polls
Post by: Windy on February 24, 2010, 02:19:43 PM
Quote from: Xarcell on February 24, 2010, 09:00:57 AM
Quote from: Windy on February 24, 2010, 08:19:04 AM
Quote from: Xarcell on February 23, 2010, 08:54:50 PM
Quote from: Windy on November 25, 2009, 05:11:37 PM
Quote from: Xarcell on November 24, 2009, 06:25:10 PM
In 2.0 RC2 is there not a way to trim back some of the duplicate material with the polls? Perhaps at least have only one "poll" catbg? Or have the polls in the same container?

In previous versions of SMF it doesn't look that bad, but in 2.0 RC2 it's kinda ruined. It looks ghetto...


Well the reason I did that is because the buttons to modify the polls, which where previously located inside the container, are now located on the outside.

Would it take alot of work to mod it to place the buttons on the outside of the container? Would it be ok for me to hire someone to change it?
I presume you mean inside of the container, as the buttons are already on the outside, which is causing the porblem, I would say overly it's rather easy assuming you know what you're doing, it just won't fit in with the existing curve style.

Do I have your permission to hire someone to try and alter it and make it show only one set of buttons? I would use it for my own private use, but can give it to you afterwards if necessary if you want to allow the public to use it.
Sure, do as you like, if you want to post the changes that you had to make here, that's fine too.
Title: Re: Additional Polls
Post by: howl.nsp on February 27, 2010, 10:56:04 AM
Adding 1.1.11 to this mod is safe, ¿could be added for a next version of it?
Title: Re: Additional Polls
Post by: Alpha_4762 on March 04, 2010, 03:45:05 PM
Hi Guys!

Is this mod working on 1.1.11?
Title: Re: Additional Polls
Post by: GPM on March 07, 2010, 01:29:02 PM
i too would like to install it for .11
Title: Re: Additional Polls
Post by: imrich on March 15, 2010, 07:25:59 PM
Any update needed for this for 2.0 RC3?
Title: Re: Additional Polls
Post by: Alpha_4762 on March 17, 2010, 01:55:27 PM
http://custom.simplemachines.org/mods/index.php?mod=2113 (http://custom.simplemachines.org/mods/index.php?mod=2113)

Use that mod to emulate 1.1.10. Then you will be able to install it to 1.1.11.
Title: Re: Additional Polls
Post by: Lou69 on May 02, 2010, 01:36:33 PM
Hello Windy,

This mod is exactly what I need for my site, however, I am running SMF 2.0 RC 3.

Have you by chance, any future plans to update this mod for RC 3?


Best regards,

Lou

:)
Title: Re: Additional Polls
Post by: C4G-TK on May 11, 2010, 11:00:58 PM
Quote from: Lou69 on May 02, 2010, 01:36:33 PM
Hello Windy,

This mod is exactly what I need for my site, however, I am running SMF 2.0 RC 3.

Have you by chance, any future plans to update this mod for RC 3?


Best regards,

Lou

:)


I installed this tonight on RC3 by using the 1b package on the mod page and by EMULATING RC2.
There was just one error in the installation.  The last error of the DisplayTemplate.php file.

'remove_poll' => array('test' => 'can_remove_poll', 'text' => 'poll_remove', 'image' => 'admin_remove_poll.gif', 'lang' => true, 'custom' => 'onclick="return confirm(\'' . $txt['poll_remove_warn'] . '\');"', 'url' => $scripturl . '?action=removepoll;topic=' . $context['current_topic'] . '.' . $context['start']),

replace w/
'remove_poll' => array('test' => 'can_remove_poll', 'text' => 'poll_remove', 'image' => 'admin_remove_poll.gif', 'lang' => true, 'custom' => 'onclick="return confirm(\'' . $txt['poll_remove_warn'] . '\');"', 'url' => $scripturl . '?action=removepoll;topic=' . $context['current_topic'] . '.' . $context['start'] . ';' . $context['session_var'] . '=' . $context['session_id']),

I've tested it out and I am not receiving any errors in my log.  I created a couple test polls and removed the polls and everything was clean.

Good luck!
Title: Re: Additional Polls
Post by: Lou69 on May 16, 2010, 11:50:52 AM
C4G-TK

I had forgotten to check this thread. Thanks for the information about installing this to RC3.

I am going to take a close look at the changes and see if there are going to be any issues with custom theme.

I will let you know how it works out.

thanks,

Lou

Title: Re: Additional Polls
Post by: C4G-TK on May 16, 2010, 11:55:07 AM
Hope it works out for you.  That was the only edit I had to change in order to get it to work.  Good luck!
Title: Re: Additional Polls
Post by: Lou69 on May 16, 2010, 08:41:07 PM
Arrrrrrggggggh (pirate talk) ..... :)  it did not work. Everything passed the test but the one change you mentioned. I made the manual change but the old style poll remained in effect.

I will take a closer look at this later this week.
Title: Re: Additional Polls
Post by: C4G-TK on May 16, 2010, 11:41:35 PM
Quote from: Lou69 on May 16, 2010, 08:41:07 PM
I made the manual change but the old style poll remained in effect.

What actually do you mean by "style"?

This mod allows you to...
1- make a poll like you normally would
2- go back into the post and then add another poll to it (making it two polls attached to same thread)
3- repeat as necessary.

Will try to help you towards the end of week if you need help.  Attached pics of a test I did after installing that shows two polls attached to one post on RC3.

Title: Re: Additional Polls
Post by: chinaren on June 12, 2010, 05:00:09 AM
Hello Windy!


I do love this mod, and I've been using it for a while now on my forums.  However, just recently I've run into problems.  I think it may be that I've upgraded to 1.1.11 or something, but now whenever someone tries to delete a poll they get:


QuoteSession verification failed. Please try logging out and back in again, and then try again.


...or some such.  


I'm running version 1.0 of your mod, so I tried to install version 1.1, but as I've got 1.0 installed it wouldn't upgrade.


So I decided to remove the mod.  However, the 'uninstall' option has gone from my forum packages list.  So I tried to get the manual instructions from the mod, but that doesn't seem to be working either.


Help!  Could you please point me at a working link for uninstall instructions?  (Or if you've an idea how to fix th error, that would do too). Many thanks!

Title: Re: Additional Polls
Post by: Windy on June 12, 2010, 11:26:05 AM
That's a known issue with 1.1.11.  The easiest way to uninstall it is to use version emulate and emulate the version that it supports, which would be 1.1.9 for the 1.0 version and 1.1.10 for the other, otherwise if you want to uninstall it manually you need to select those versions when getting the manual install instructions.

see http://dev.simplemachines.org/mantis/view.php?id=4072 for the fix
Title: Re: Additional Polls
Post by: chinaren on June 12, 2010, 07:42:25 PM
Thanks Windy, I'll give it a go.  :)
Title: Re: Additional Polls
Post by: chinaren on June 12, 2010, 08:15:40 PM
Ha!  Okay, the remove poll option in the poll still fails, but the remove poll option at the bottom now works, so that will do!


Thanks Windy.  This mod is used a lot on my forum!   ;D
Title: Re: Additional Polls
Post by: Bugo on June 22, 2010, 10:40:02 AM
When I use two and/or more polls, I get these errors: see screenshot
Title: Re: Additional Polls
Post by: C4G-TK on June 22, 2010, 12:18:48 PM
Quote from: Bugo on June 22, 2010, 10:40:02 AM
When I use two and/or more polls, I get these errors: see screenshot

I've had that, too.  I don't correct it though because it will separate the poll from the other poll & topic.  It evidently comes up as an error under the routine maintenance because my guess is the 2nd poll attaches itself to the 1st poll and not to the topic.  The poll functionality still works, it just comes up in that.  Ignoring and hitting "No" doesn't seem to effect anything with the forum since it doesn't come up in the error log itself.
Title: Re: Additional Polls
Post by: chinaren on June 22, 2010, 05:38:28 PM
Quote from: C4G-TK on May 11, 2010, 11:00:58 PM

I installed this tonight on RC3 by using the 1b package on the mod page and by EMULATING RC2.
There was just one error in the installation.  The last error of the DisplayTemplate.php file.



HI there C4G-TK, how do you emulate RC2?  I'm upgrading my board to 2RC3, and it tells me to bugger off when I try installing this.  >:(
Title: Re: Additional Polls
Post by: C4G-TK on June 22, 2010, 10:57:09 PM
Quote from: chinaren on June 22, 2010, 05:38:28 PM
Quote from: C4G-TK on May 11, 2010, 11:00:58 PM

I installed this tonight on RC3 by using the 1b package on the mod page and by EMULATING RC2.
There was just one error in the installation.  The last error of the DisplayTemplate.php file.



HI there C4G-TK, how do you emulate RC2?  I'm upgrading my board to 2RC3, and it tells me to bugger off when I try installing this.  >:(


First, slap your computer for telling you to bugger off!

Then, go into ADMIN > PACKAGES > BROWSE PACKAGES
--- At the bottom right of the page you will see "Advanced" which is a link.
--- Click on the word "Advanced"
--- Replace the SMF 2.0 RC3 with SMF 2.0 RC2
--- Hit apply
---Install the mod as normal
---Go back and change it back to SMF RC2.0 RC3
---Hit Apply

... and then tell your computer to bugger off!  ;D
Title: Re: Additional Polls
Post by: chinaren on June 23, 2010, 12:19:29 AM
Ah, thanks, that did it!  8)
Title: Re: Additional Polls
Post by: C4G-TK on June 23, 2010, 12:48:16 AM
No problem.  Glad it worked!
Title: Re: Additional Polls
Post by: Windy on June 24, 2010, 01:29:39 PM
New version up, pretty much just bug fixes.  Fixes the invalid argument error that shows up on SplitTopics for 1.1.11/2.0 RC3 and the issue with Maintenance for 2.0 RC3. I've also made it easier to uninstall, making use of 2.0's database tag to allow of a complete uninstallation (removing database changes), for 1.1.11 I've enclosed a file that can be dropped in the forum root to do the same thing, I've also wild carded the uninstall version so it should uninstall for 2.x/1.1.x instead of just the version it was installed for.
Title: Re: Additional Polls
Post by: chinaren on June 27, 2010, 04:22:36 AM
Awesome!  Just installed it on my 2RC3 board and (so far!!) it's all hunky dory!  


Many thanks for this.  This mod is most useful.  Most useful indeed.  ;D


Quote from: Windy on June 24, 2010, 01:29:39 PM

New version up, pretty much just bug fixes.  Fixes the invalid argument error that shows up on SplitTopics for 1.1.11/2.0 RC3 and the issue with Maintenance for 2.0 RC3. I've also made it easier to uninstall, making use of 2.0's database tag to allow of a complete uninstallation (removing database changes), for 1.1.11 I've enclosed a file that can be dropped in the forum root to do the same thing, I've also wild carded the uninstall version so it should uninstall for 2.x/1.1.x instead of just the version it was installed for.
Title: Re: Additional Polls
Post by: zijO on August 03, 2010, 12:02:26 PM
Made 30 polls in forums test section,
When I moved it to other section I lose all of them except first one  I made.
Is any way to fix this?
Title: Re: Additional Polls
Post by: zijO on August 04, 2010, 01:17:21 AM
Sorry may fault,
The other forum section uses copy of default template (different colour)
Great mod / thanks
Title: Re: Additional Polls
Post by: zijO on August 10, 2010, 10:36:34 AM
How to change order of polls?
Title: Re: Additional Polls
Post by: zijO on August 10, 2010, 11:06:03 AM
ah it's alphabetical order :-)
Title: Re: Additional Polls
Post by: dmacleo on November 11, 2010, 12:52:31 PM
smf 2 rc4 tried applying update that was posted today,
get this error:

Duplicate key name 'id_topic'
File: /xxxx/xxx/xxx/Packages/temp/install2.php
Line: 59

line 59 looks to be blank.
I did have this installed on rc3, do I have to delete database tables?
if so which ones? I did not see anything that stood out to me.
Title: Re: Additional Polls
Post by: Windy on November 13, 2010, 09:31:48 AM
I don't believe that's supposed to happen, what database system are you using?
Title: Re: Additional Polls
Post by: dmacleo on November 13, 2010, 12:03:15 PM
MySql 5.0.91 running off site5.com host.
Title: Re: Additional Polls
Post by: Windy on November 14, 2010, 05:58:34 AM
It looks like it might be a bug with SMF, fortunately I think I can work around it.
Title: Re: Additional Polls
Post by: Rafferty on November 14, 2010, 07:28:29 PM
Quote from: dmacleo on November 11, 2010, 12:52:31 PM
smf 2 rc4 tried applying update that was posted today,
get this error:

Duplicate key name 'id_topic'
File: /xxxx/xxx/xxx/Packages/temp/install2.php
Line: 59

line 59 looks to be blank.
I did have this installed on rc3, do I have to delete database tables?
if so which ones? I did not see anything that stood out to me.

Same error here:

Duplicate column name 'id_topic'
File: /home/www/xxxxxx.com/forum/Packages/temp/install2.php
Line: 43
Title: Re: Additional Polls
Post by: C4G-TK on November 14, 2010, 08:01:45 PM
I had this installed on RC3 as well and just upgraded to RC4 and got the same error.
I had uninstalled my mods prior to the upgrade and this is only the third mod that I've tried to install since that point.
(Simple Portal and Ad Management Mod being the only other two.)


Duplicate key name 'id_topic'
File: /home/xxxxxxx/public_html/Packages/temp/install2.php
Line: 59

ALTER TABLE measfonx_ilm_polls
ADD INDEX id_topic (id_topic)
File: /home/xxxxxxx/public_html/Packages/temp/install2.php
Line: 59

54: $smcFunc['db_add_index'] (
55: '{db_prefix}polls',
56: array(
57: 'columns' => array('id_topic'),
58: )
==>59: );
60:
61: $request = $smcFunc['db_query'] ('', '
62: SELECT p.id_poll
63: FROM {db_prefix}polls AS p
64: WHERE p.id_topic = 0 OR p.id_topic IS NULL'
65: );





Installed the MOD by doing this:
I just went into PHP MyAdmin in my database and went to  _polls and deleted the id_topic field.
Then, I just went back into Admin for the packages and installed without any problem.
Title: Re: Additional Polls
Post by: Windy on November 15, 2010, 07:45:57 AM
I hope you deleted just the index and not the whole column.

Anyway, I've added a new version that specifically fixes this issue, if you aren't encountering this issue then there is no reason to upgrade.
Title: Re: Additional Polls
Post by: Rafferty on November 15, 2010, 07:59:56 AM
Still getting the following:

QuoteDuplicate column name 'id_topic'
File: /home/www/xxxxxx.com/forum/Packages/temp/install2.php
Line: 43
Title: Re: Additional Polls
Post by: dmacleo on November 15, 2010, 12:24:22 PM
Quote from: Windy on November 15, 2010, 07:45:57 AM
I hope you deleted just the index and not the whole column.

Anyway, I've added a new version that specifically fixes this issue, if you aren't encountering this issue then there is no reason to upgrade.
seems to work, thank you.
Title: Re: Additional Polls
Post by: Windy on November 15, 2010, 09:34:39 PM
Quote from: Rafferty on November 15, 2010, 07:59:56 AM
Still getting the following:

QuoteDuplicate column name 'id_topic'
File: /home/www/xxxxxx.com/forum/Packages/temp/install2.php
Line: 43
database system?
Title: Re: Additional Polls
Post by: Rafferty on November 15, 2010, 10:01:20 PM
what do you mean?
Title: Re: Additional Polls
Post by: dmacleo on November 16, 2010, 06:41:28 AM
think shes asking for specifics on server, mysql version and php version.
Title: Re: Additional Polls
Post by: Rafferty on November 16, 2010, 07:15:18 AM
Quote from: Windy on November 15, 2010, 09:34:39 PM
Quote from: Rafferty on November 15, 2010, 07:59:56 AM
Still getting the following:

QuoteDuplicate column name 'id_topic'
File: /home/www/xxxxxx.com/forum/Packages/temp/install2.php
Line: 43
database system?

PHP5 -     * Server version: 5.0.32-Debian_7etch1~bpo.1-log
    * Protocol version: 10
    * User:
    * MySQL charset: UTF-8 Unicode (utf8)

Web server

    * Apache/2.2.11 (Unix) mod_ssl/2.2.11 OpenSSL/0.9.7e
    * MySQL client version: 5.0.32
    * PHP extension: mysql

Helpful or no?

Title: Re: Additional Polls
Post by: dmacleo on November 16, 2010, 08:58:33 AM
don't know if its helpful but before I tried installing the newer version I deleted all files related to it including the one in temp folder.
I also had to clear cookies/temp files on pc, not sure why or which of these 2 worked but it then installed fine for me.
Title: Re: Additional Polls
Post by: Windy on November 19, 2010, 06:13:51 AM
Atm I'm sort of at a loss as to what it could be, utf8 is the only thing that I could imagine that might skew it, but I had no issue installing it more than once on a forum using utf8. So at the moment I can only assume that the files have been altered, which is probably pretty unlikely, or for some reason your mysql isn't returning the correct tables names or they're in a format that doesn't allow it to pickup that they're the same. Either way, I haven't been able to reproduce the error.

I might suggest perhaps that I do up a custom package for you to try to install that would spit out some debug information that should help diagnose the issue.
Title: Re: Additional Polls
Post by: Rafferty on November 19, 2010, 06:25:17 AM
I can only add that this has only occurred after I upgraded from RC3 to 4. Additional Polls worked fine before that on RC3
Title: Re: Additional Polls
Post by: Windy on November 20, 2010, 12:11:10 AM
Quote from: Rafferty on November 19, 2010, 06:25:17 AM
I can only add that this has only occurred after I upgraded from RC3 to 4. Additional Polls worked fine before that on RC3
Did you ever have to reinstall it though?
Title: Re: Additional Polls
Post by: Rafferty on November 20, 2010, 02:55:25 AM
No, only after rc4 upgrade
Title: Re: Additional Polls
Post by: Windy on November 20, 2010, 07:51:33 AM
So it's probably not an issue with the version.
Title: Re: Additional Polls
Post by: Rafferty on November 20, 2010, 04:44:11 PM
Well I dont know, it worked fine before but wont install after rc4
Title: Re: Additional Polls
Post by: Windy on November 21, 2010, 11:44:03 AM
Quote from: Rafferty on November 20, 2010, 04:44:11 PM
Well I dont know, it worked fine before but wont install after rc4
It worked fine before because you never had to reinstall it, hence it's never had to deal with the column already existing.  For whatever reason, either the method that checks if the column exists has been modified, or mysql isn't returning the correct column names or is returning them in an alternative format so its not being detected as already being there.
Title: Re: Additional Polls
Post by: Rafferty on November 21, 2010, 05:34:02 PM
Hmmm Norv from smf was in there a week ago tinkering, dont know if he changed anything though
Title: Re: Additional Polls
Post by: Windy on November 22, 2010, 12:48:01 AM
if you want you could try posting your DbPackages-mysql.php in the sources directory and i can tell you if there's been any changes.
Title: Re: Additional Polls
Post by: Rafferty on November 26, 2010, 03:54:10 AM
my backup?, what do you mean?
Title: Re: Additional Polls
Post by: Windy on November 26, 2010, 05:16:59 AM
Go to your smf installation directory, then go to the sources directory, download the DbPackages-mysql.php file and attach it to your post.
Title: Re: Additional Polls
Post by: Assault on December 05, 2010, 02:36:24 PM
When installing to the core theme this happens
   4.   Replace   ./Themes/core/Display.template.php   Test failed
Find[Select]
<div class="content" id="poll_options">
Replace[Select]
<div class="content poll_options">


Shouldn't it remain <div class="content" id="poll_options">

Title: Re: Additional Polls
Post by: Windy on December 06, 2010, 06:26:48 PM
no. I would imagine it's different to core which is why it fails.
Title: Re: Additional Polls
Post by: Assault on December 07, 2010, 07:23:41 PM
Okay, and another thing, in core you need to use this snippet of code in the core/Display.Template.php
// They are allowed to vote! Go to it!
else
{
echo '
<form action="', $scripturl, '?action=vote;topic=', $context['current_topic'], '.', $context['start'], ';poll=', $context['poll']['id'], '" method="post" accept-charset="', $context['character_set'], '" style="margin: 0px;">
<table>
<tr>
<td colspan="2">';

// Show a warning if they are allowed more than one option.
if ($context['poll']['allowed_warning'])
echo '
', $context['poll']['allowed_warning'], '
</td>
</tr><tr>
<td>';


It gives you a syntax error shouldn't there be a } at the end like this
// They are allowed to vote! Go to it!
else
{
echo '
<form action="', $scripturl, '?action=vote;topic=', $context['current_topic'], '.', $context['start'], ';poll=', $context['poll']['id'], '" method="post" accept-charset="', $context['character_set'], '" style="margin: 0px;">
<table>
<tr>
<td colspan="2">';

// Show a warning if they are allowed more than one option.
if ($context['poll']['allowed_warning'])
echo '
', $context['poll']['allowed_warning'], '
</td>
</tr><tr>
<td>';}

Title: Re: Additional Polls
Post by: Windy on December 08, 2010, 01:40:00 AM
I wouldn't know, it was built for Curve, for the tests that failed, if you look at the changes it made to curve, it should give you a decent idea as to where it should go, offhand that doesn't look right to me, although keep in mind its been ages since I've gone over the code.
Title: Re: Additional Polls
Post by: dry3210 on December 22, 2010, 09:27:23 PM
I get this when trying to install now after upgrading

Duplicate column name 'id_topic'
File: /public_html/Packages/temp/install2.php
Line: 43
Title: Re: Additional Polls
Post by: chinaren on December 25, 2010, 10:35:47 PM
Yah, I'm also getting...


QuoteDuplicate column name 'id_topic'
File: .../Packages/temp/install2.php
Line: 43


Any ideas?  I'd really like to put this one back in!
Title: Re: Additional Polls
Post by: Rafferty on December 28, 2010, 07:24:53 AM
Quote from: chinaren on December 25, 2010, 10:35:47 PM
Yah, I'm also getting...


QuoteDuplicate column name 'id_topic'
File: .../Packages/temp/install2.php
Line: 43


Any ideas?  I'd really like to put this one back in!

Ive had this error now on 3 mods so far when trying to reinstall in RC4
Title: Re: Additional Polls
Post by: Windy on January 03, 2011, 06:51:12 PM
yeah, it's really an SMF issue, one that I imagine is somewhat unique to your configuration as I can't reproduce it.
Title: Re: Additional Polls
Post by: chinaren on January 03, 2011, 07:04:05 PM
Quote from: Windy on January 03, 2011, 06:51:12 PM
yeah, it's really an SMF issue, one that I imagine is somewhat unique to your configuration as I can't reproduce it.


Do you know where we should start looking to try and fix this?  There are three of us with this, in this thread, so it's obviously not all that unique!  :)


Is it a database error?  I had additional polls installed before, and it 'fell out' when I upgraded to SMF C2.4, so obviously all the tables are still there, maybe some code too.
Title: Re: Additional Polls
Post by: Windy on January 03, 2011, 11:26:46 PM
Quote from: chinaren on January 03, 2011, 07:04:05 PM
Quote from: Windy on January 03, 2011, 06:51:12 PM
yeah, it's really an SMF issue, one that I imagine is somewhat unique to your configuration as I can't reproduce it.


Do you know where we should start looking to try and fix this?  There are three of us with this, in this thread, so it's obviously not all that unique!  :)


Is it a database error?  I had additional polls installed before, and it 'fell out' when I upgraded to SMF C2.4, so obviously all the tables are still there, maybe some code too.

It is a database error, caused by the code not being able to detect the column for some unknown reason.

The key thing to find out would be to find out why it can't detect that the column exists. If you open up DbPackages-mysql.php from the Sources directory and look for the function smf_db_add_column and then log the contents into a file or something of both the $columns and $column_info variables right before the first foreach loop. You may also want to log whether it made it into the if statement in that first foreach loop, that way we can also tell if it was able to find the column and the issue is elsewhere.

Then you can run it again after and post the contents of the logs so I can see what's going on.
Title: Re: Additional Polls
Post by: katb on January 07, 2011, 11:04:54 PM
Getting  above error on SMF 2.0 RC4

Duplicate column name 'id_topic'
File: /home/newthat/public_html/New/Packages/temp/install2.php
Line: 43

Look like a know issue in this version SMF 2.0 RC4
Title: Re: Additional Polls
Post by: drvanitus on February 04, 2011, 12:59:28 AM
OMG thank you so much, didn't know such mod existed, this is priceless.  Now we can vote on all new applicants in the same thread with ease.  Thanks!
Title: Re: Additional Polls
Post by: Teerapat on April 05, 2011, 01:27:29 PM
Cannot install on 2.0 RC5  :(
Title: Re: Additional Polls
Post by: truegret on April 14, 2011, 01:44:12 PM
Greetings -

This would be a very useful tool for me.  It does not appear to be compatible with 1.1.13 yet.  Is there an eta for this availability?

As you can tell, I am new to the forum and SMF (great tool!), and am not yet familiar with the mod install process - meaning when I requested the install docs, the response was something like "it appears this version is not compatible with 1.1.13".  Any help is greatly appreciated!

Thanks
Title: Re: Additional Polls
Post by: atomicblue on May 17, 2011, 12:09:18 PM
Yeah, one of the other admins on my forum has said it doesn't work above RC4. Would love to see an upgrade!
Title: Re: Additional Polls
Post by: dougiefresh on June 15, 2011, 03:34:43 PM
Thank you for the wonderful mod!  I thought I'd let everybody know that when I updated my forum from 2.0 RC5 to 2.0 Gold, I had to reinstall all my mods.  This mod installed without issues and using 2.0 RC5 emulation.  Hope this info helps someone!

Just an after-thought: I just downloaded what is supposed to be v1.2.2.  Uploaded it to the package manager (PM) on my forum and PM is showing that it is 1.2.1......  Thought I'd tell ya if you were interested  :P
Title: Re: Additional Polls
Post by: JPND on July 21, 2011, 08:08:45 AM
I cant get this to work on 1.1.14 - any idea if it will be, it would be invaluable to us!

Thanks in advance.
Title: Re: Additional Polls
Post by: studiowi33 on September 06, 2011, 05:14:27 PM
Quote from: dry3210 on December 22, 2010, 09:27:23 PM
Duplicate column name 'id_topic'
File: /public_html/Packages/temp/install2.php
Line: 43

Has anyone discovered a way around this for 2.0? I'd really like to offer our members this option.

-s.w
Title: Re: Additional Polls
Post by: chelseaphil on September 23, 2011, 09:08:32 AM
I would to be able to use this mod.  But it is not working with 1.1.15.  Is there any likelihood of this happening?
Title: Re: Additional Polls
Post by: sShadowSs on October 03, 2011, 04:13:37 PM
Has anyone tried this with 2.0.1 ?
It does install if you edit package-info.xml file and does work but because of a few errors during the install it messes up the order of poll answers.  This has to be a simple fix, but I unfortunately don't know how to code.

Can anyone help?
Thanks.
Title: Re: Additional Polls
Post by: nivlac on November 03, 2011, 01:14:33 AM
Wendy,

I used the emulate feature to get the 1.2.2 version of this mod to install under SMF 2.0.1, however, it only works in the default theme and gives errors on the install for the SMF Core and other Curve based themes. I didn't select any of those options though and I suppose that is why it installed.

I tested it by creating three poll questions and then announced it to the admins on my forum. It let me vote and as far as I can tell there were no issues. I still haven't gotten the announcement yet, but it has only been a few minutes and sometimes the mail is slow from the server my forum is hosted on.

This is a useful mod, and I'm requesting that you update this mod to SMF 2.0.1. I, and others I'm sure, would certainly appreciate it.

Thanks.
Title: Re: Additional Polls
Post by: nakins on December 18, 2011, 01:39:31 PM
I would like to add my voice to the rest asking for a version that will work in 2.0.1. This is really a great feature. I wish I could use it.
Title: Re: Additional Polls
Post by: walbrzych2014.pl on December 23, 2011, 08:52:12 AM
When will be a safe version for 2.0.1?
Title: Re: Additional Polls
Post by: webmaven on February 16, 2012, 09:44:20 AM
New to all of this.  How do I add this to my site?  I click the link to get the manual but seems like a lot of work for this.  Is there an auto loader?

Thanks
Title: Re: Additional Polls
Post by: valmount on March 02, 2012, 12:01:51 AM
not support for "SMF 2.0.2 | SMF © 2011, Simple Machines"
Title: Re: Additional Polls
Post by: Herdervriend on March 08, 2012, 11:52:31 AM
When will this mod be available for 2.0.2? I seriously need it.
Title: Re: Additional Polls
Post by: Kriostasys on May 10, 2012, 04:40:35 AM
I've got to work on 2.0.2
but not is if allowed to publish the modifications that I've done
Title: Re: Additional Polls
Post by: mageguild on June 01, 2012, 12:52:13 PM
I have not been able to get this MOD to install on 2.0 or 2.0.2
Title: Re: Additional Polls
Post by: C4BR3R4 on October 09, 2012, 08:49:43 AM
Do any of gotten it to work in version 2.0.2?

QuoteDuplicate column name 'id_topic'
Archivo: ...\Packages\temp\install2.php
Línea: 43
Title: Re: Additional Polls
Post by: Shambles on October 09, 2012, 09:14:35 AM
I gotten it to work in my 2.0.2 version :)
Title: Re: Additional Polls
Post by: C4BR3R4 on October 09, 2012, 09:48:43 AM
I get out, you know if I can post the modified package?
Title: Re: Additional Polls
Post by: Shambles on October 09, 2012, 09:54:07 AM
Quote from: C4BR3R4 on October 09, 2012, 09:48:43 AM
I get out, you know if I can post the modified package?

I don't know what you mean by "I get out", but if you've changed the package to obviate the need to emulate to 2.0 RC4, then no you cannot repost the package without permission from the author.


EDIT: you changed the wording of your post but I still don't think you can repost the package
Title: Re: Additional Polls
Post by: C4BR3R4 on October 09, 2012, 09:54:56 AM
The package modified to work in SMF v2.0.2 'AdditionalPolls_1_2_2_-_SMF2_0_2' "Pending approval for author"

The author did not connect the board from July 16, 2011 and can not send private messages. Send email for approval.
Title: Re: Additional Polls
Post by: iksa on January 26, 2013, 08:07:01 PM
I believe there is a bug in the package-info.xml file of this mod. It says this installs only on 2.0 RC4. I believe this mod would be fully functional also on any other 2.* version. At least I got it installed just fine on my 2.0.3 when I first removed that restriction from package-info.xml.
Title: Re: Additional Polls
Post by: Arantor on January 26, 2013, 08:09:55 PM
It's not a bug, it just hasn't been updated by the author for a little over 2 years (when 2.0 RC4 was the then-current version of SMF)

The fact it works is more a testament to the lack of change in SMF for polls since then.

There's always the emulate option in the package manager to avoid editing the package.
Title: Re: Additional Polls
Post by: iksa on January 26, 2013, 08:26:38 PM
ok, thanks
Title: Re: Additional Polls
Post by: borish on October 05, 2014, 06:04:14 AM
This mod fails to install in SMF 2.0.9 (with 2.0 RC4 emulation). I get an error for a replacement operation in Sources/Display.php for

$context['show_view_results_button'] = $context['allow_vote'] && (!$context['allow_poll_view'] || !$context['poll']['show_results'] || !$context['poll']['has_voted']);
$context['poll']['show_view_results_button'] = $context['poll']['allow_vote'] && (!$context['poll']['allow_poll_view'] || !$context['poll']['show_results'] || !$context['poll']['has_voted']);
Title: Re: Additional Polls
Post by: dougiefresh on January 11, 2015, 06:33:35 PM
Here is what SMF 2.0 RC4 through SMF 2.0.8 has in Sources/Display.php:
$context['show_view_results_button'] = $context['allow_vote'] && (!$context['allow_poll_view'] || !$context['poll']['show_results'] || !$context['poll']['has_voted']);

Here is what SMF 2.0.9 has in Sources/Display.php:
$context['show_view_results_button'] = $context['allow_vote'] && $context['allow_poll_view'] && !$context['poll']['show_results'];

Suggested change to that operation (requires edits to the mod):
$context['poll']['show_view_results_button'] = $context['poll']['allow_vote'] && $context['poll']['allow_poll_view'] && !$context['poll']['show_results'];
Title: Re: Additional Polls
Post by: jack_1985 on January 14, 2015, 08:48:13 AM
Hi everyone,

I installed this mod at SMF 2.0.8. It is functional, but the following error pops up:

Quote8: Undefined index: poll_hide
in Polls.php
Line: 737

This error appears when someone tries to edit a poll that they have created. The visibility of the votes also seems to reset, when a poll is edited.

Does anyone have any ideas what the cause of this could be, or how it could be fixed?

Any suggestions would be greatly appreciated!  :)
Title: Re: Additional Polls
Post by: dougiefresh on January 15, 2015, 08:15:49 PM
@jack_1985: Without seeing your Sources\Polls.php file, I (and probably anyone else) couldn't even begin to help you....
Title: Re: Additional Polls
Post by: jack_1985 on January 16, 2015, 10:24:55 AM
Thank you for your reply, dougiefresh. It is much appreciated. I have attached the Polls.php file like you suggested.

If you would be willing to take a look, please note that no changes have been made to this file except the ones required by this mod. I have also double-checked all of those changes myself, and as far as I could tell everything appears to be correct...

Could the problem perhaps lay elsewhere?
Title: Re: Additional Polls
Post by: jack_1985 on February 26, 2015, 02:16:17 AM
Could someone please have a look if they you can find a spare minute? :)
Title: Re: Additional Polls
Post by: dougiefresh on February 26, 2015, 05:15:16 PM
Quote from: jack_1985 on January 14, 2015, 08:48:13 AM
Hi everyone,

I installed this mod at SMF 2.0.8. It is functional, but the following error pops up:

Quote8: Undefined index: poll_hide
in Polls.php
Line: 737

This error appears when someone tries to edit a poll that they have created. The visibility of the votes also seems to reset, when a poll is edited.

Does anyone have any ideas what the cause of this could be, or how it could be fixed?

Any suggestions would be greatly appreciated!  :)
I'm sorry.  I completely lost track of things....

In Sources/Poll.php, change this line (at line 737):
$_POST['poll_hide'] = (int) $_POST['poll_hide'];
to this statement:
$_POST['poll_hide'] = (int) isset($_POST['poll_hide']) ? $_POST['poll_hide'] : 0;

Hope this helps you.
Title: Re: Additional Polls
Post by: jack_1985 on February 27, 2015, 05:51:16 AM
Thanks dougiefresh!

The error has disappeared. :)

But when editing an existing poll, the visibility option always resets to "show results to everyone". It's only possible to select "run for XXX days" when you first post the poll.

Is that normal?
Title: Re: Additional Polls
Post by: dougiefresh on February 27, 2015, 02:00:52 PM
Quote from: jack_1985 on February 27, 2015, 05:51:16 AM
But when editing an existing poll, the visibility option always resets to "show results to everyone". It's only possible to select "run for XXX days" when you first post the poll.

Is that normal?
Wouldn't have the faintest.  I'll be honest with ya, I've worked 67 hours in 6 days and I don't feel like looking through the code to try and figure out what is going on right now, as it's not my mod....
Title: Re: Additional Polls
Post by: Gwenwyfar on April 17, 2015, 05:45:09 PM
Anyone knows if this can this work with ssi_showPoll by poll ID? (if you use topic id it just grabs the first poll)

(Just asking before I go around seeing if I can find out a way... and if I do I'll post it here later :) )
Title: Re: Additional Polls
Post by: Gwenwyfar on June 04, 2015, 03:48:24 PM
Didn't find a way yet, but you can change the topic's poll id in the database to change what shows up in the ssi poll for that topic. Maybe making ssi work by poll id would solve this.
Title: Re: Additional Polls
Post by: Stanyy on July 16, 2015, 06:50:24 PM
Bug Report:

For multiple choice polls (e.g make two choices). When a 'guest' votes for two choices, the first option in the poll becomes bold instead of the the two choices the guest voted for. This is somewhat misleading because the correct votes are actually being recorded.
I also noticed that this only happens when more than one option is selected. If only one option is selected, the correct choice is shown in bold text.

Logged users do not experience this problem though.
Title: Re: Additional Polls
Post by: nend on September 30, 2015, 04:35:58 PM
Small bug

When viewing results the "View Results" button is still active with the "Voting Options" button.

Display.template.php
Code
$context['show_view_results_button'] = $context['poll']['show_view_results_button'];

Small work around
$context['show_view_results_button'] = !$context['poll']['allow_return_vote']?$context['poll']['show_view_results_button']:false;
Title: Re: Additional Polls
Post by: bharat on January 21, 2018, 09:43:43 AM
I am looking for additional polls for version 2.0, is it going to be avalaible?
Title: Re: Additional Polls
Post by: Shambles on January 21, 2018, 03:50:14 PM
Quote from: bharat
I am looking for additional polls for version 2.0, is it going to be avalaible?

What do you mean? I have this mod installed in 2.0.15
Title: Re: Additional Polls
Post by: Dwev on February 09, 2018, 10:33:49 AM
Quote from: Shambles on January 21, 2018, 03:50:14 PM
What do you mean? I have this mod installed in 2.0.15

I tried installing it in SMF 2.0.15 (with a custom theme) and it screwed up my forum so badly that I to replace all SMF files from my backup.

So an update would be very welcome, because I would really like to be able to use this Mod.
Title: Re: Additional Polls
Post by: -Rock Lee- on February 12, 2018, 06:14:18 PM
Quote from: Dwev on February 09, 2018, 10:33:49 AM
Quote from: Shambles on January 21, 2018, 03:50:14 PM
What do you mean? I have this mod installed in 2.0.15

I tried installing it in SMF 2.0.15 (with a custom theme) and it screwed up my forum so badly that I to replace all SMF files from my backup.

So an update would be very welcome, because I would really like to be able to use this Mod.

Nor emulating the version installed correctly? What theme was he using?


Regards!
Title: Re: Additional Polls
Post by: Dwev on February 14, 2018, 11:06:53 AM
I was using emulation, the theme is a custom one (based on Bootstrap) which still can be seen here (https://www.applezone.nl) at this moment (this will change soon).
Title: Re: Additional Polls
Post by: bharat on April 24, 2018, 04:15:06 AM
After I installed this mod I can't see the option remove vote anymore which becomes visible if you check the box Allow users to change their votes. What can be the reason? Can someone help me with this issue?
Title: Re: Additional Polls
Post by: bharat on May 16, 2018, 02:58:19 AM
Can someone answer my question? What can be done?
Title: Re: Additional Polls
Post by: Dwev on May 31, 2018, 04:29:27 AM
I think all development on this Mod has stopped, and that's a huge pity.