Jump to content

Recommended Posts

Hi,

 

I'm wanting to create a small and simple questionnaire form on my site that will have roughly 10 or so questions on with checkboxes for the user to answer by. There will be two options of each question to be answered, a yes and a no checkbox. However, if the user answers a question as a yes, I would like to have another question appear automatically underneath it. Was wondering how i would go about this? Can this be done via dreamweavers dynamic behaviours/bindings or do i need to do it via handcoding php or ajax or something?

 

Any guidance on this would be greatly appreciated.

 

thanks

Link to comment
https://forums.phpfreaks.com/topic/145582-creating-a-questionnaire-form/
Share on other sites

Here is how it looks at the moment... just a simple form with questions and a yes and a no checkbox underneath each question.

Just needing to know how i can create a behaviour that would spawn a new question directly underneath the users previously POSITIVELY answered question.

 

 

coursesearchapp.jpg

 

edit, you got the image working.

 

Anyways, the questions appearing after one is answered can be done with plain old javascript, unless you want them saved after the answer the question (then that would become ajax.) I'd recommend using radio buttons instead of checkboxes for yes/no questions, so they can only select one option.

 

Well, if the user answers the second or "spawned" question positive aswell, then I will have some subjects appear underneath that.

So for the first question lets say was answered as a yes and its spawned question as a yes, I would have subjects in relation to industrial university subjects appear (about 10 or so). If not, the user moves on.

 

Anyway, I'm not exactly hot on either javascript or ajax, are there any tutorials around that i could adapt to this kind of thing?

 

oh and good idea about the the radio buttons, will sort that now. cheers

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.