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.
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″]?
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?
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.
Everything I tested worked out fine. Good job!