Hi,
I'm kind of a PHP novice, but am recently taking up a challenge from a frined to come up with a PHP survey script on individual personalities traits that has these requirements in 2 parts :-
PART 1 :
(1)total of 24 questions , but with no question phrases upfront.
(2)each survey question is a direct selectable-answers type with 4 answer options, next to each option are 2 radio buttons.
(3)the participant simply selects one option under "MOST" & another option under "LEAST" according to the 2 descriptions that matches their personality.
For a clearer understanding, kindly view a sample of survey question at this URL :-
http://www.wisdom-consultancy.com/survey_sample.html
PART 2 :
(4)once all 24 questions are answered, participant clicks on "submit" button.
(5)the survey script will then assign each set of selected answers ( one "Most" & one "Least" ) to the corresponding "alphabet score" of either "A", "B", "C" or "D". Refer to URL example under diagram heading "Answer Score".
(6)the survey script will then add up all the scores under "Most" column & "Least" column & finally present them in total frequencies of "A"s, "B"s, "C"s & "D"s. Refer to URL example for tabulated scores.
It's indeed a very challenging one for me.....can anyone offer any guidelines on how to get started..??
Any help would be greatly appreciated.
a survey of a different kind...
Moderator: General Moderators
First off are you going to be using a database with this?? second of all you should read the php manual on some of that... go to http://www.php.com...
and on the sample why do you have "Survey Question" and "Answer Score"??

and on the sample why do you have "Survey Question" and "Answer Score"??
Yes, a database is required.
At the same time, I've been reading the PHP material ...but would need help in a practical way like what functions or commands to use to create the 1st part of the survey question as shown in the URL sample.
This "Survey Question" sample is an example of the screen interface that the participant would see & interact with by selecting the 2 answers , i.e. one answer under "Most" column & another answer under "Least" colomn.
The "Answer Score" sample seen in the URL is the part of php script that is not displayed but instead works in the backend to assign it's respective score ( i.e. A,B,C or D ) to the selected answers on screen.
Hope my explanation helps.
Any further help would be greatly appreciated.
simplejoe
At the same time, I've been reading the PHP material ...but would need help in a practical way like what functions or commands to use to create the 1st part of the survey question as shown in the URL sample.
This "Survey Question" sample is an example of the screen interface that the participant would see & interact with by selecting the 2 answers , i.e. one answer under "Most" column & another answer under "Least" colomn.
The "Answer Score" sample seen in the URL is the part of php script that is not displayed but instead works in the backend to assign it's respective score ( i.e. A,B,C or D ) to the selected answers on screen.
Hope my explanation helps.
Any further help would be greatly appreciated.
simplejoe
Maybe this will get you somewhat started?
Code: Select all
<pre>
<?php
if (!empty($_POST)) {
print_r($_POST);
print_r(array_count_values($_POST));
}
?>
<form method="post">
<input name="1" type="radio" value="1">Most <input name="1" type="radio" value="0">Least
<input name="2" type="radio" value="1">Most <input name="2" type="radio" value="0">Least
<input name="3" type="radio" value="1">Most <input name="3" type="radio" value="0">Least
<input name="4" type="radio" value="1">Most <input name="4" type="radio" value="0">Least
<input type="submit" value="Send" />
</form>
</pre>