Is there a way to add a block to the site that is linked to a certain section in the forums so that when you make a new poll that it shows up in the block. Just thought it would be a cool idea. Let me know. Thanks in advance.
I too would be interested in seeing this. I know you can link to an external poll, but that defeats the purpose of having it on the forums at all.
Hope someone can do it!
I believe this should do it:
ssi_showPoll($topic);
I got the code from this post:
http://www.tinyportal.net/smf/index.php?topic=1930.0
that thread is super confusing to me
same here..... is there a way to create a new section in the forums for polls only and then just tie it in with that?
Although I'm not an SMF guru at first glance all you should have to do is replace $topic in the parenthesis with the top # as shown in the URL
ssi_showPoll(topic=3752);
Quote from: HaxXxoR on March 28, 2006, 10:55:32 PM
same here..... is there a way to create a new section in the forums for polls only and then just tie it in with that?
I'm sure there is, but to have one poll show at a time other variables would need to be specified to determine latest poll created. The PHP block code would still use $topic to display a single poll.
And what kind of block do we put ssi_showPoll(topic=3752); in
phpbox
There is no "polls only" feature within SMF. I been requesting it since last year, and was really hoping it would be in 1.1, but it's not.
If you want to help support adding that feature to SMF, so that in certain boards, user's can only make polls, reply to this thread: http://www.simplemachines.org/community/index.php?topic=65873.0
I get this error written in the block i tried to put poll on :
Parse error: parse error, unexpected '=' in /home/webrain/public_html/skyshark/forum/Sources/Load.php(1607) : eval()'d code(34) : eval()'d code on line 1
Block is a php one and only has :"ssi_showPoll(topic=36);" in it
TP 0.8.6 SMF 1.1RC2
Try it without no quotes "" in it and it should work
lol it has no quotes in it lol ;)
oh lol sorry it looked like it.
i got it to work by not using the topic=, just the topic number. instead of ssi_showPoll(topic=36); i use ssi_showPoll(36); of course changing the topic number to match yours. the only thing is, dont use frames from theme, at least the one i tried looked like crap. also, it only pulls the results, you can't actually vote from the box which is what i was hoping for. unless i am not doing something correct anyways.
Work fine, that's a good solution for now ;D
Creat a PHP bloc and add this
ssi_showPoll(number_your_poll_topic);
Ex:
topic= 36.0 has been post a poll then u just using this
ssi_showPoll(36);
Thank rbh for code ;)
Quote from: rbh on April 20, 2006, 01:55:48 AM
i got it to work by not using the topic=, just the topic number. instead of ssi_showPoll(topic=36); i use ssi_showPoll(36); of course changing the topic number to match yours. the only thing is, dont use frames from theme, at least the one i tried looked like crap. also, it only pulls the results, you can't actually vote from the box which is what i was hoping for. unless i am not doing something correct anyways.
Adding a quick little link below the poll results fixes that. :)
ssi_showPoll(99);
echo '<small><a href="http://forums.blahblahblah.com/index.php?topic=99">vote here</a>';
SSI Poll = Very good. :) The flash poll I was using looked so nice, but it would dump tenths of a percent into the last option, throwing off all of the percentages.
Quote from: Larathiel on June 19, 2006, 10:44:13 AM
Quote from: rbh on April 20, 2006, 01:55:48 AM
i got it to work by not using the topic=, just the topic number. instead of ssi_showPoll(topic=36); i use ssi_showPoll(36); of course changing the topic number to match yours. the only thing is, dont use frames from theme, at least the one i tried looked like crap. also, it only pulls the results, you can't actually vote from the box which is what i was hoping for. unless i am not doing something correct anyways.
Adding a quick little link below the poll results fixes that. :)
ssi_showPoll(99);
echo '<small><a href="http://forums.blahblahblah.com/index.php?topic=99">vote here</a>';
Sweet, thank you. I've been waiting simple like this that utilized the existing forum s/w.
Is there a way to modify the way that the polls look in the block? I just need the percentages and number of votes to display on their own line, and more spaced out. Right now it's a bit on the squashed side. Also, the bar for the highest rated option likes to extend beyond the block's boarder.
Bippity Boppity Bump.
:)
In my opinion, TinyPortal should have its own, independent, poll system. I never really liked putting a poll block based upon a forum posted poll.
The poll system should:
- allow for either enabling or disabling guests from casting votes
- allow for enabling or disabling multiple votes from same member
- allow for time period between multiple votes from same member when enabled
- have its own independent table
- allow for any number of polls
... just to name a few.
It would be best if it were built right into TP and have its own admin configuration area in the SMF CP under the TP Section. In lieu of that, I wouldn't mind a mod or even block snippet to fill in until Bloc decides it really should be in TP. ;)
For people interested in making SMF polls working with TP --> our top notch crack PHP coder Thurnok (http://www.tinyportal.net/smf/index.php?action=profile;u=7091) has devised a method to make it work...please read instructions here (http://www.tinyportal.net/smf/index.php?topic=5679.msg65481#msg65481)
The code that was like this one didn't close out the small... making everything below it block wise messed up... (atleast on my site)
ssi_showPoll(99);
echo '<small><a href="http://forums.blahblahblah.com/index.php?topic=99">vote here</a></small>';
For some reason the quote thing went all crazy lol so yeah...
EDIT:
I tried to use the code on a left/right block, the title runs on if its longer, and the bar will go out as far as the title...
Anyway to make that smaller???
Try following this (http://www.tinyportal.net/smf/index.php?topic=9869.0), should work right if you follow the whole thing through...
aahhh there it is!! I was looking for that link lol - totally puzzled as to what happend to the link in my post :2funny:
im gona update the snippets and put only 1 poll link as urs in there :up:
Sorry Aku, I messed you up.. hehe.. I posted that one so the info would be in the first post but forgot to tell ya. hehe.. sorry bro