View Full Version : Pop-up quiz that will send users to different places depending on answers- help!

07-24-2002, 03:54 AM
Ok, seriously, I need more than just advice and I'm hating asking for this but.. I have wrist injuries which make any typing painful.. regardless, I ignore the pain as much as possible to (sporadically) work on my webpages, though serious coding is quite out of the question, thus I'm asking for someone to not just point me in the right direction, but actually do the coding. It can often take me weeks or even months to do what most people can do in hours or days, so please don't think I'm just being lazy, this is a very real, very painful and very annoying problem.

Secondly, due to this problem, I don't have a job. Which means I have no money.. which means all I'd be able to offer in return for your time and effort is my sincere gratitude and your name and URL on my page.

Now, if you've read that far and are willing to help here is what I'm trying to do:

I'm trying to set up a series of 24 multiple choice questions. Clicking on the link to start the quiz will open up a little pop-up window that will contain the first question. Once the first answer is picked (by radio button) and "Submit" button clicked, the little window will refresh and ask the second question, then third and so on till done. When the last question is answered, the pop-up will close, and the main page with then be directed to a certain page according to the answers chosen.

Basically, for the quiz part, I'd like to give the answers of each question an alphabetic value and add them, creating a string of letters which would then be associated with a certain webpage.

Due to the nature of this project, there would be some instances where there would not yet be a page set up for certain combinations of answers. As such any unassociated letter strings would have to be directed to the "oops, sorry, nothing yet" page.

On top of this, the script would need to allow me to be able to go in and create new letter string associations. Ie.. where choosing certain answers would have sent you to the oops page before, I can now say that string would be associated with xyz.htm and it would then send users there.

If anyone is interested, please feel free to contact me.. I may not answer for a few days as I will need a serious break after this post.


Off to take some aspirin and wish it was Percoset :(

07-24-2002, 07:21 PM
Hy, Sorry to hear about your wrists :(

Will i've come up with a way to do what your thinking,

This is how i picture it -------

1. the user clicks a button or link to open the a window wich has the first question in it.

2. The user answers the question and then clicks a button
a. this button when clicked does this
a1. Sends the letter (a,b,c,d) to a hidden form box within the main page and then sends the user to the next question.

3. This situation continues till there are no more questions.

4. The last question has a different button, this button does this.
a. Checks the main windows hidden fields and reads checks them with prewrittin arrays, if any check out -- they go to a spicified page, if no they go to a different one.

In this small quick example i use alerts instead of pages, just to make it eiser to test, and there are no questions yet.
Just mix up the arrays and the form fields to test it.
But those form fields will be writtin to and then those arrays will be checked by the fields, it might just work, Plus its cross browser.

I only used 9 entrys for the array, just for the test.

If ya like my aproach to this, and want to continue in this way, you can email me at ACJavascript@aol.com

Hope this helps :D:D:D