TP-Docs
HTML5 Icon HTML5 Icon HTML5 Icon
TP on Social Media

Recent

Welcome to TinyPortal. Please login or sign up.

Members
  • Total Members: 3,963
  • Latest: BiZaJe
Stats
  • Total Posts: 195,917
  • Total Topics: 21,308
  • Online today: 884
  • Online ever: 8,223 (February 19, 2025, 04:35:35 AM)
Users Online
  • Users: 1
  • Guests: 325
  • Total: 326
  • @rjen

[Block] Poll specified or most recent specified board

Started by Greybrow, January 28, 2007, 11:17:34 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

martino

Hmmm...I guess that makes sense. Thank you for the reply.

Also, one more thing which I found was that when I have two polls in one block (http://evaforum.com/forums/index.php) and when you click on one option from either one of the polls the corresponding number of the chosen option will be selected in the other one, but the vote will be submitted just for the one that was selected by the user. Is this some kind of a bug?

P.S. Sorry, but if you want to test it out on that site I posted you'll have to register... :(

MinasC

great great great block there !!! thnx a lot !!!

keith021773

Great code!!     

I wonder if it would be possible to have a random poll block from all of the polls that are still active (voting still allowed).  That way it even new members could find old polls..   

Greybrow

Quote from: martino on March 05, 2007, 07:33:51 PMAlso, one more thing which I found was that when I have two polls in one block (http://evaforum.com/forums/index.php) and when you click on one option from either one of the polls the corresponding number of the chosen option will be selected in the other one, but the vote will be submitted just for the one that was selected by the user.

Hm... I suppose it's not a bug it's a feature ;)
I didn't actually check two polls voting, but I understand what is happening.
Unfortunately it can't be fixed. Not in easy way at least.


Gourgi

this snippet isn't working well with me :(
i'm using SMF 1.1.2 and TP 0.9.7.1 .

when i specify a certain poll
// show the poll from topic 6
tp_showPoll(6);   

it displays the poll (id=6)
(this is the working part of the snippet for me)

but when i specify board 2.0 to display the newest poll from board 2.0
tp_showPoll(null,'echo',2);
it keeps displaying the overall newest poll that i created in board 3.0 !!

same thing happens even if i specify the poll's id (id=5) from board 2.0
tp_showPoll(5,'echo',2);

what i'm doing wrong ?  :idiot2:

Greybrow

hm...
About your board number 2.
No idea.
It works for me just fine... Did you check it, if it's really the 3 board, not the 2?

to the second one:
// show the most recent poll from the board number 5
// tp_showPoll(null,'echo',5);           
//
// keep in mind, that if board given, topic is ignored
// so it will display the same as above
// tp_showPoll(34,'echo',5) 

insanemustang

Worked great on my website, http://www.bamanation.net

I am hoping I can figure out how to add a specific poll instead of the most recent because I want the one on there to stay for a little while.

Greybrow

My friend found an error (and solution :) ), that was causing strange behaviour when not only one board had polls.
I'll update the code in few minutes.

G6Cad

Please use the code tags when you post the code this time.  ;) 

This website is proudly hosted on Crocweb Cloud Website Hosting.