Hello,
I have been reading material all over the internet and trying to understand the Api that is provided here. how ever i am stack ... i have read the solutions offered by the users here and overflow but adding a response to a survey is playing me.
Code:
$answers_to_survey = array(
"75195X10X117" => "A1",
"75195X10X118" => "A1",
"75195X11X119" => "A2",
"75195X11X120" => "Y",
"75195X11X121" => "Y",
"75195X12X122" => "A1",
"75195X12X123" => "Y",
"75195X12X124" => "N",
"75195X12X125" => "A2",
"75195X13X126" => "A4",
"75195X13X127" => "A2",
"75195X13X128" => "N",
"75195X13X129SQ001" => "Y",
"75195X13X129SQ002" => "Sales",
"75195X14X130" => "Y",
"75195X14X131" => "N"
);
//adding the response to the survey
$respond_to_survey = $myJSONRPCClient->add_response( $sessionKey, $survey_id, $answers_to_survey);
echo '<pre>'; print_r($respond_to_survey); echo '<pre/>';
this is the little piece of php that i am trying to use to send some sort of response to the survey so that i can expand it further.
however its able to echo the number for the response but when i check in the response table there is nothing entered. am i doing something wrong?
Code:
"75195X10X117" => "Once a year [A1]",
"75195X10X118" => "Less than 24 hours [A1]",
"75195X11X119" => "Satisfactory [A2]",
"75195X11X120" => "Yes [Y]",
"75195X11X121" => "Yes [Y]",
"75195X12X122" => "1-5 Minutes [A1]",
"75195X12X123" => "Yes [Y]",
"75195X12X124" => "No [N]",
"75195X12X125" => "5-10 Times [A2]",
"75195X13X127" => "Satisfactory [A2]",
"75195X13X128" => "Just Okay [A3]",
"75195X13X129SQ001" => "Yes [Y]",
"75195X13X129SQ002" => "Sales",
"75195X14X130" => "Yes [Y]",
"75195X14X131" => "No [N]"
i also tried that format and it did not work.
I am using Version 2.72.3+171020 of limesurvey.
Let me attach some pictures for clarity.
Any help is welcome.