From e1caf89b1102bf453d8fdab710d0b8f62f8d236b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jos=C3=A9=20Loguercio?= Date: Tue, 11 Oct 2016 21:01:43 -0500 Subject: [PATCH] Fix Dropdown survey question type results saving --- main/survey/ch_dropdown.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/main/survey/ch_dropdown.php b/main/survey/ch_dropdown.php index 7c2e40d037..a03b0f611b 100644 --- a/main/survey/ch_dropdown.php +++ b/main/survey/ch_dropdown.php @@ -33,8 +33,8 @@ class ch_dropdown extends survey_question public function render(FormValidator $form, $questionData = array(), $answers = '') { $name = 'question' . $questionData['question_id']; - array_unshift($questionData['options'], '--'); - $form->addSelect($name, null, $questionData['options']); + $data = array(0 => '--') + $questionData['options']; + $form->addSelect($name, null, $data); if (!empty($answers)) { $form->setDefaults([$name => $answers]); }