vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 2.x Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=4)
-   -   LeSane's Store Add-on for VB Quiz (https://vborg.vbsupport.ru/showthread.php?t=44279)

xxxsaint 10-03-2002 10:00 PM

LeSane's Store Add-on for VB Quiz
 
***** LESANE's STORE ADD-ON FOR VBQUIZ *****

Tested and Running smooth on VB 2.2.6

*****Integrate LeSane's Store with TWT Commish's VBQUIZ*****

ALL CREDIT for the code in this hack goes to LeSane who is one of the most helpful people I've had the pleasure to work with. I am releasing this Add-on with his permission and only because he's busy working on other goodies right now. Also a big thank you goes out to TWT Commish for creating VBQuiz and adding a lot of enjoyment to our sites. :D

Q.What does this do ?
A.This awards users of a 10 question quiz 10 points for every correct answer.
If they get all 10 questions right, then it awards them 1000 points as a bonus.
Instructions include both the standard 10 points per correct answer installation
AND installation if you want it to have the 1000 points bonus.

************************************************** **

Files to modify : 1
quiz.php

Installation time : 2 minutes or less
************************************************** **

I will do my best to provide support for this add on - but just so you know , I'm a total noob , this is my first hack release and I was basically the testor for it, Lesane did all the coding from ideas that I had.

Enjoy and click on INSTALL if you use and like this add-on!!

Installation instructions included in the attached file:

Vile 10-04-2002 02:45 PM

Cool. Thanks for the hack, installed :)

Dean C 10-04-2002 06:20 PM

hmmm didn't lesane post this lil addon in the requests forum (or am i mistake :)?)

:D

- miSt

xxxsaint 10-05-2002 01:35 AM

you're mistaken

Quote:


I am releasing this Add-on with his permission and only because he's busy working on other goodies right now.


Dean C 10-05-2002 12:43 PM

oh lol... sorry didn't see that first time round ;)

- miSt

DarkDraco07 10-05-2002 02:00 PM

is there a way to add this to the vBindex?

xxxsaint 10-05-2002 02:29 PM

I'm not sure , I don't have vBindex :D

Lesane 10-16-2002 12:53 PM

Great work 'xxxsaint'. Glad you released it.

NTLDR 10-16-2002 02:00 PM

Quote:

Originally posted by DarkDraco07
is there a way to add this to the vBindex?
I don't see how this hack can be integrated at all into vBindex, if I'm right in thinking it gives you points for the Store Hack when you answer questions correctly in vBquiz.

MPM.com 11-17-2002 10:33 PM

Fatal error: Call to a member function on a non-object in E:\webspace\resadmin\markquayle\mobilephonemadness .com\www\forums\quiz.php on line 673

(line 673 is:

$updatestore = $DB_site->query("UPDATE user SET storep=storep+'$storeamount' WHERE userid='$bbuserinfo[userid]'");

)

Can ANYONE help please?

ethics 11-18-2002 04:41 AM

Uhm, call me crazy but I don't see the quiz.php? Where do I download it from?

Keyser S?ze 12-15-2002 03:18 AM

Quote:

Originally posted by ethics
Uhm, call me crazy but I don't see the quiz.php? Where do I download it from?
same, and i dont see instructions on how to like, put up a link so members can access it, how to change questions and answers, nothings here, what gives :(

xxxsaint 12-15-2002 05:26 AM

Quote:

*****Integrate LeSane's Store with TWT Commish's VBQUIZ*****
This is just an auto-pay add on to TWT Commish's VBQUIZ through Lesane's Store. You have to have both of those hacks installed before making use of this hack.

Search for :
LeSane's Store
and
VB QUIZ

xxxsaint 12-15-2002 05:30 AM

Quote:

Fatal error: Call to a member function on a non-object in E:\webspace\resadmin\markquayle\mobilephonemadness .com\www\forums\quiz.php on line 673

(line 673 is:

$updatestore = $DB_site->query("UPDATE user SET storep=storep+'$storeamount' WHERE userid='$bbuserinfo[userid]'");

)

Can ANYONE help please?
hmm , I don't know about that one but I'm sure someone around here does , sorry , I would help if I knew :(:(:(

Keyser S?ze 12-15-2002 02:49 PM

ahh, thanks man

Zelda-King 04-22-2003 03:49 PM

I thought a link to the vB Quiz hack would be handy here.

http://www.vbulletin.org/hacks/index...ack&hackid=418

Hmm, how about an option to make people have to pay to take the quiz?

Cloudrunner 05-20-2003 11:07 PM

Just for the record, to make it so that it will give the big $$$ on 100% on any size quiz (not just those with 10 questions), modify the code slightly to look thusly:

Instead of this:

Code:

//Points = $$$
                if ($totalcorrect=='10') {
                  $storeamount = 100 * $totalcorrect;
                } else {
                  $storeamount = 10 * $totalcorrect;
                }
                $updatestore = $DB_site->query("UPDATE user SET storep=storep+'$storeamount' WHERE userid='$bbuserinfo[userid]'");
//END Points = $$$

Use this:

Code:

//Points = $$$
                if ($totalcorrect==$question_count) {
                  $storeamount = 100 * $totalcorrect;
                } else {
                  $storeamount = 10 * $totalcorrect;
                }
                $updatestore = $DB_site->query("UPDATE user SET storep=storep+'$storeamount' WHERE userid='$bbuserinfo[userid]'");
//END Points = $$$

This uses the already assigned variable: $question_count, which is the total numbers of questions assigned to the quiz. Thus if the two variables are equal, then the score is obviously 100%, and thus it will give the big $$$.

Enjoy!

)O( Cloudrunner )O(

mx3 06-16-2003 02:34 AM

Looks cool, i'll install. :D

Warlord 03-06-2004 11:01 PM

Great hack, just installed it.

Thanks XXXSaint and Lesane! :)


All times are GMT. The time now is 07:17 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01201 seconds
  • Memory Usage 1,754KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (2)bbcode_code_printable
  • (5)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (19)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.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/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.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
  • printthread_start
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete