UNC - LimeSurvey

 

PHP notice

PHP notice

Trying to get property of non-object

C:\xampp\htdocs\limesurvey\application\helpers\common_helper.php(1401)

1389 * @return array Returns array with survey info or false, if survey does not exist
1390 */
1391 function getSurveyInfo($surveyid, $languagecode='')
1392 {
1393     global $siteadminname, $siteadminemail, $languagechanger;
1394     $surveyid=sanitize_int($surveyid);
1395     $languagecode=sanitize_languagecode($languagecode);
1396     $thissurvey=false;
1397 
1398     // if no language code is set then get the base language one
1399     if (!isset($languagecode) || $languagecode=='')
1400     {
1401         $languagecode=Survey::model()->findByPk($surveyid)->language;;
1402     }
1403 
1404     //$query="SELECT * FROM ".db_table_name('surveys').",".db_table_name('surveys_languagesettings')." WHERE sid=$surveyid and surveyls_survey_id=$surveyid and surveyls_language='$languagecode'";
1405 
1406     $result = Surveys_languagesettings::model()->with('survey')->findAllByAttributes(array('surveyls_survey_id' => $surveyid, 'surveyls_language' => $languagecode));
1407     foreach ($result as $row)
1408     {
1409         $thissurvey=array();
1410         foreach ($row as $k => $v)
1411             $thissurvey[$k] = $v;
1412         foreach ($row->survey as $k => $v)
1413             $thissurvey[$k] = $v;

Stack Trace

#0
+
 C:\xampp\htdocs\limesurvey\application\helpers\expressions\em_manager_helper.php(3913): getSurveyInfo("978173")
3908             $LEM->allOnOnePage=$allOnOnePage;
3909             $LEM->processedRelevance=false;
3910             $LEM->surveyOptions['hyperlinkSyntaxHighlighting']=true;    // this will be temporary - should be reset in running survey
3911             $LEM->qid2exclusiveAuto=array();
3912 
3913             $surveyinfo = (isset($LEM->sid) ? getSurveyInfo($LEM->sid) : null);
3914             if (isset($surveyinfo['assessments']) && $surveyinfo['assessments']=='Y')
3915             {
3916                 $LEM->surveyOptions['assessments']=true;
3917             }
3918             //        $LEM->runtimeTimings[] = array(__METHOD__,(microtime(true) - $now));
#1
+
 C:\xampp\htdocs\limesurvey\application\core\Survey_Common_Action.php(217): LimeExpressionManager::StartProcessingPage(false, "/limesurvey", true)
212             Yii::app()->getController()->_showadminmenu(!empty($aData['surveyid']) ? $aData['surveyid'] : null);
213 
214             if (!empty($aData['surveyid']))
215             {
216 
217                 LimeExpressionManager::StartProcessingPage(false, Yii::app()->baseUrl,true);  // so can click on syntax highlighting to edit questions
218 
219                 $this->_surveybar($aData['surveyid'], !empty($aData['gid']) ? $aData['gid'] : null);
220 
221                 if (isset($aData['display']['menu_bars']['surveysummary']))
222                 {
#2
+
 C:\xampp\htdocs\limesurvey\application\controllers\admin\surveyadmin.php(1625): Survey_Common_Action->_renderWrappedTemplate("survey", array(), array("surveyid" => "954223", "gid" => null, "qid" => null, "display" => array("menu_bars" => array("surveysummary" => true))))
1620     * @param array $aData Data to be passed on. Optional.
1621     */
1622     protected function _renderWrappedTemplate($sAction = 'survey', $aViewUrls = array(), $aData = array())
1623     {
1624         $this->getController()->_css_admin_includes(Yii::app()->getConfig('adminstyleurl')."superfish.css");
1625         parent::_renderWrappedTemplate($sAction, $aViewUrls, $aData);
1626     }
1627 
1628 }
2012-10-25 14:37:19 Apache/2.4.2 (Win32) OpenSSL/1.0.1c PHP/5.4.4 Yii Framework/1.1.10