Check out the LimeSurvey source code on GitHub!

Filling array with answerscodes

More
6 years 2 months ago - 6 years 2 months ago #52345 by Rene01
Hello all,

I have made some PHP code to display a graph to the user at the end of my survey. The code does some calculations on the answers(56) and makes the graph. The questions are 56 List(radio) 2 options A or B. Then A = 1 and B = 0, all in 1 group.

My calculation-code starts with this array:

$answers1 = array( 1 => 1,0,0,1,1,0,1,1,0,1,0,1,0,1,0,1,0,1,0,0,0,1,0,1,1,1,0,1,0,1,1,0,1,0,1,0,1,0,1,1,1,0,1,0,1,0,1,0,1,0,1,0,1,0,1,0);

Now my question is, what is the code to fill this array from the survey.
I have been browsing through printanswers.php and statistics_user.php but I havent been able to get it going yet.

Greetings Rene

Edit: I fixed it!
Last Edit: 6 years 2 months ago by Rene01.

Please Log in to join the conversation.

Imprint                   Privacy policy         General Terms & Conditions         Revocation information and revocation form