Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 2.x > vBulletin 2.x Full Releases
FAQ Community Calendar Today's Posts Search

Closed Thread
 
Thread Tools
Details »»

Version: , by Admin (Coder) Admin is offline
Developer Last Online: Nov 2024 Show Printable Version Email this Page

Version: 2.0.x Rating:
Released: 10-20-2001 Last Update: Never Installs: 11
 
No support by the author.

I know a lot people wanted and asked for this, so here it is, just for you! (and me )

Pretty simple actually.
This adds an option to the new poll screen (screenshot 1), that lets you choose between a regular poll (like it is now), or a multiple choice poll.
If the latter is selected, instead of radio buttons there will be check boxes (screenshot 2).

I also must say that installation is rather simple.
All you need to do is edit 2 files, and 1 template.
The rest is done automatically.
This is the place to thank Bane that generously let me use his great installer!

Without further ado, here's the installer:
Installer - just upload to your admin folder and run in your browser.
(note: all installation is reversable. uninstallation can be done from the installer)
For a small add-on (not included in the installer), please see this page.

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #12  
Old 10-22-2001, 08:30 AM
cyrus's Avatar
cyrus cyrus is offline
 
Join Date: Oct 2001
Posts: 159
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

beautiful hack BUT, when I use it with vbportal, it doesnt allow multiple selections on the portal

can anyone help ?
  #13  
Old 10-22-2001, 08:36 AM
cyrus's Avatar
cyrus cyrus is offline
 
Join Date: Oct 2001
Posts: 159
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

also, gives an error that I have not selected an option even when I know I have , so I cant vote full stop !
  #14  
Old 10-22-2001, 09:45 AM
Bane's Avatar
Bane Bane is offline
 
Join Date: Oct 2001
Posts: 411
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Cyrus, you'll likely have to do some additional hacking if you want this to appear in the front page poll.
  #15  
Old 10-22-2001, 10:17 AM
BluSmurf BluSmurf is offline
 
Join Date: Nov 2001
Posts: 50
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

great hack, installed with ease!
  #16  
Old 10-22-2001, 12:56 PM
c0bra
Guest
 
Posts: n/a
Default

Another great hack FireFly! Installation was a breeze, thanks very much...
  #17  
Old 10-22-2001, 01:45 PM
GenSec GenSec is offline
 
Join Date: Oct 2001
Posts: 156
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally posted by Cyrus
beautiful hack BUT, when I use it with vbportal, it doesnt allow multiple selections on the portal

can anyone help ?
  • Add temlate P_polloption_mult
    Code:
    <tr>
      <td bgcolor="#DFDFDF" width="5%"><input type="checkbox" name="allvotes[$P_option[number]]" value="yes"></td>
      <td bgcolor="#DFDFDF" colspan="3"><smallfont>$P_option[question]</smallfont></td>
    </tr>
  • Find in vbpstuff.php
    Code:
    eval("\$P_pollbits .= \"".gettemplate("P_polloption")."\";");
    Replace with
    Code:
    // Multi-Choice Hack
          if ($P_pollinfo[multiple]!=0) {
            eval("\$P_pollbits .= \"".gettemplate("P_polloption_mult")."\";");
          } else {
            eval("\$P_pollbits .= \"".gettemplate("P_polloption")."\";");
          }
    // Multi-Choice Hack
That's all.

P.S. Bravo FireFly!
  #18  
Old 10-22-2001, 04:37 PM
cyrus's Avatar
cyrus cyrus is offline
 
Join Date: Oct 2001
Posts: 159
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

there is no file called vbpstuff.php in version 2.0.3 if vbportal !!!

  #19  
Old 10-22-2001, 05:05 PM
Admin's Avatar
Admin Admin is offline
Coder
 
Join Date: Oct 2023
Location: Server
Posts: 1
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Small addon re floleb7's first post.
This will display the number of voters with multi choice polls, instead of number of votes.

In showthread.php, find this:
Code:
  $counter=0;
  while ($counter++<$pollinfo[numberoptions]) {
    $pollinfo[numbervotes]+=$splitvotes[$counter-1];
  }
and add this right below it:
Code:
  if ($pollinfo[multiple]!=0) {
    $getvoters=$DB_site->query_first("SELECT COUNT(DISTINCT(userid)) AS voters FROM pollvote WHERE pollid='$pollid'");
    $pollinfo[voters]=$getvoters[voters];
  } else {
    $pollinfo[voters]=$pollinfo[numbervotes];
  }
Now in showthread_pollresults template, replace $pollinfo[numbervotes] votes with $pollinfo[voters] voters.

Easy wasn't it?
  #20  
Old 10-22-2001, 05:09 PM
cyrus's Avatar
cyrus cyrus is offline
 
Join Date: Oct 2001
Posts: 159
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

what about me FF ??
  #21  
Old 10-22-2001, 05:15 PM
RobAC RobAC is offline
 
Join Date: Oct 2001
Posts: 314
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I get all kinds of undefined function errors such as cpheader and makelinkcode.
Closed Thread


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 09:10 AM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.05263 seconds
  • Memory Usage 2,300KB
  • Queries Executed 25 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (5)bbcode_code
  • (1)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (3)pagenav_pagelink
  • (11)post_thanks_box
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (10)postbit_onlinestatus
  • (11)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete