• Resolved bbuerger

    (@bbuerger)


    Hi,

    when I set [yop_poll id=”-1″] I expect to get the latest active poll like it is stated in the faq.

    I have two polls. One has ended, one has not started yet. So I expect to see none at all.

    What I get is the one that has ended. And I do not see the result but the poll itself. I can even select an option but I cannot vote. href of the vote button is #.

    How can I get the active poll and none at all if none is active?

    Regards,
    Brigitta

    • This topic was modified 2 years, 2 months ago by bbuerger.
Viewing 8 replies - 1 through 8 (of 8 total)
  • Thread Starter bbuerger

    (@bbuerger)

    I had a look at the database. Both polls have status = active. The one which has not started yet is still not shown. Why is the other not excepted? I do need to see the results of the finished poll in a post. But I do not want to see a poll which is not a poll anymore.

    Plugin Author YOP

    (@yourownprogrammer)

    Hey Brigitta

    On the poll thats ended, can you let us know what settings you have for “Show Results”?

    You can find this setting when editing the poll under Options -> Results tab.

    Thread Starter bbuerger

    (@bbuerger)

    Hi,

    I originally only had after voting. I added after the ending. The outcome is the same.

    Results are shown for [yop_poll id=”1″]. For [yop_poll id=”-1″] the LAST poll is shown. I had only identical clones so I did not see it before.

    I also had a look with Query Monitor. This is the statement executed:
    SELECT max(id)
    FROM wepe_kwup_yoppoll_polls
    WHERE status = ‘published’

    After that only details are loaded for poll nr. 3 (a new clone, not started yet)

    All polls (ended, runnung, not started) have status published. And all poll elements of all polls have status = active.

    Plugin Author YOP

    (@yourownprogrammer)

    Thank you..

    Will run some tests with the same settings on our end.

    What would be the expected behaviour when using [yop_poll id=”-1″]?

    Thread Starter bbuerger

    (@bbuerger)

    The expected behaviour would be that the latest active poll is shown. Active meaning you can currently vote. So it has to be between start and end dates. No future votes and no finished votes should be shown.

    For some cases it might help to be able to activate and deactivate votes manually. It depends if people want to show future votes in advance or if they want to see former results until the next vote is started.

    But I have three votes now and the middle, open (=active) vote is not even shown. It has to be possible to create a future vote while another is still running.

    Plugin Author YOP

    (@yourownprogrammer)

    Hello

    We have released a new version that addresses this issue.

    Can you give it a try?

    Thread Starter bbuerger

    (@bbuerger)

    Hi,

    thank you very much for your quick reaction.
    On a first view it seems to work as expected. Only active votes are shown. When no vote is active none is shown. I will do more extensive tests later.

    Thread Starter bbuerger

    (@bbuerger)

    Everything I tested worked out fine. Good job!

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘Show active polls not working correctly’ is closed to new replies.