PHP notice

Undefined offset: 1

/var/www/limesurvey/application/controllers/admin/export.php(570)

558             echo "*Define Variable Properties.\n";
559             foreach ( $fields as $field )
560             {
561                 if ( ! $field['hide'] )
562                 {
563                     $label_parts = strSplitUnicode(str_replace('"','""',stripTagsFull($field['VariableLabel'])), $length_varlabel-strlen($field['id']));
564                     //if replaced quotes are splitted by, we need to mve the first quote to the next row
565                     foreach($label_parts as $idx => $label_part)
566                     {
567                         if($idx != count($label_parts) && substr($label_part,-1) == '"' && substr($label_part,-2) != '"')
568                         {
569                             $label_parts[$idx] = rtrim($label_part, '"');
570                             $label_parts[$idx + 1] = '"' . $label_parts[$idx + 1];
571                         }
572                     }
573                     echo "VARIABLE LABELS " . $field['id'] . " \"" . implode("\"+\n\"", $label_parts) . "\".\n";
574                 }
575             }
576 
577             // Create our Value Labels!
578             echo "*Define Value labels.\n";
579             foreach ( $fields as $field )
580             {
581                 if ( isset($field['answers']) )
582                 {

Stack Trace

#2
+
 /var/www/limesurvey/application/core/Survey_Common_Action.php(101): CAction->runWithParamsInternal(export, ReflectionMethod, array("sid" => "652723", "sa" => "exportspss", "iSurveyId" => "652723", "iSurveyID" => "652723"))
096             $oMethod = new ReflectionMethod($this, $sDefault);
097         }
098 
099         // We're all good to go, let's execute it
100         // runWithParamsInternal would automatically get the parameters of the method and populate them as required with the params
101         return parent::runWithParamsInternal($this, $oMethod, $params);
102     }
103 
104     /**
105     * Some functions have different parameters, which are just an alias of the
106     * usual parameters we're getting in the url. This function just populates
#6
+
 /var/www/limesurvey/application/controllers/AdminController.php(177): CController->run("export")
172                     $this->redirect(array('/admin/authentication/sa/login'));
173                 }
174 
175             }
176 
177             return parent::run($action);
178     }
179 
180     /**
181     * Routes all the actions to their respective places
182     *
#10
+
 /var/www/limesurvey/index.php(214): CApplication->run()
209         die (sprintf('%s should be writable by the webserver (766 or 776).', $sDefaultRuntimePath));
210     }
211 }
212 
213 Yii::$enableIncludePath = false;
214 Yii::createApplication('LSYii_Application', $config)->run();
215 
216 /* End of file index.php */
217 /* Location: ./index.php */
2017-09-25 15:25:37 Apache/2.4.7 (Ubuntu) Yii Framework/1.1.17