Discussion Forums  >  Plugins, Customizing, Source Code

Replies: 2    Views: 764

nadthevlad
Code is Art
Profile
Posts: 1025
Reg: Jun 07, 2012
Denver
21,850
01/05/13 10:25 AM (13 years ago)

adding quiz questions and answers via plugin index.php

I am working on a custom quiz plugin. Right now my quiz questions and answers are are in a file separate friom BT_config.txt. (test1.txt) What I would like to do is be able to add questions and answers via the control panel just like the current buzztouch quiz plugin does. But I am having trouble figuring out how to set up the index.php so that the questions and answers are under their own childItems json entry. https://www.dropbox.com/s/ujjqhs0al36w8up/test1.txt https://www.dropbox.com/s/e8y412l8v6azwde/BT_config.txt https://www.dropbox.com/s/e8y412l8v6azwde/BT_config.txt http://youtu.be/8goE-BnNEtk
 
ATRAIN53
Code is Art
Profile
Posts: 1755
Reg: Nov 17, 2011
Chicago
26,450
like
01/05/13 04:58 PM (13 years ago)
I like what I seeing here... Quiz is pretty complex plug-in. I'd love to see a new one, esp with some definate True/False and maybe other new options. ..keep at it! This is a complex question.... I don't think a post is going to answer it completely unless it's from you know who. I'm guessing you studied the existing quiz plug in. Lots of code in there. The menus use childitems too. Good code to study there. You are self hosted and have tied a simple JSON varaible/custom property in a basic plugin you made to a screen already? I'm wondering if one of the BT webinars that has been done recently might provide some insight? David has touched on this topic very recently. A good example with some 'students' that covered child items well. Stobe also has a quizmaker tool that might be of interest? He's a JSON ninja and the snippet keeper might help you learn how this could work with your code?
 
nadthevlad
Code is Art
Profile
Posts: 1025
Reg: Jun 07, 2012
Denver
21,850
like
01/06/13 11:10 AM (13 years ago)
From watching that first plugin webinar I was able to cut, paste and modify the php for the quiz properties. Its getting to that second level in the json properties for the quiz questions and answers that is getting me. I messed up adding the links to the forum. So here is the index.php. https://www.dropbox.com/s/xoerl3outbj8bl9/index.php I'll check the webinars again.
 

Login + Screen Name Required to Post

pointerLogin to participate so you can start earning points. Once you're logged in (and have a screen name entered in your profile), you can subscribe to topics, follow users, and start learning how to make apps like the pros.