/var/www/html/application/models/QuestionTemplate.php(268)
256 257 /** 258 * In the future, could retrieve data from DB 259 */ 260 public function setConfig() 261 { 262 if (!isset($this->oConfig)) { 263 $oQuestion = $this->oQuestion; 264 $sTemplatePath = $this->getTemplatePath(); 265 $sFolderName = self::getFolderName($oQuestion->type); 266 $this->sTemplateQuestionPath = $sTemplatePath . '/survey/questions/answer/' . $sFolderName; 267 $xmlFile = $this->sTemplateQuestionPath . '/config.xml'; 268 $this->bHasConfigFile = is_file($xmlFile); 269 270 if ($this->bHasConfigFile) { 271 $sXMLConfigFile = file_get_contents(realpath($xmlFile)); // Entity loader is disabled, so we can't use simplexml_load_file; so we must read the file with file_get_contents and convert it as a string 272 $this->xmlFile = $xmlFile; 273 $this->oConfig = simplexml_load_string($sXMLConfigFile); 274 275 $this->bLoadCoreJs = $this->oConfig->engine->load_core_js; 276 $this->bLoadCoreCss = $this->oConfig->engine->load_core_css; 277 $this->bLoadCorePackage = $this->oConfig->engine->load_core_package; 278 $this->bHasCustomAttributes = !empty($this->oConfig->attributes); 279 280 // Set the custom attributes
#0 |
+
–
/var/www/html/application/models/QuestionTemplate.php(268): is_file("/survey/questions/answer/file_upload/config.xml") 263 $oQuestion = $this->oQuestion; 264 $sTemplatePath = $this->getTemplatePath(); 265 $sFolderName = self::getFolderName($oQuestion->type); 266 $this->sTemplateQuestionPath = $sTemplatePath . '/survey/questions/answer/' . $sFolderName; 267 $xmlFile = $this->sTemplateQuestionPath . '/config.xml'; 268 $this->bHasConfigFile = is_file($xmlFile); 269 270 if ($this->bHasConfigFile) { 271 $sXMLConfigFile = file_get_contents(realpath($xmlFile)); // Entity loader is disabled, so we can't use simplexml_load_file; so we must read the file with file_get_contents and convert it as a string 272 $this->xmlFile = $xmlFile; 273 $this->oConfig = simplexml_load_string($sXMLConfigFile); |
#1 |
+
–
/var/www/html/application/models/QuestionTemplate.php(76): QuestionTemplate->setConfig() 71 { 72 self::$instance = new QuestionTemplate(); 73 self::$instance->oQuestion = $oQuestion; 74 self::$instance->aViews = array(); 75 self::$instance->getQuestionTemplateFolderName(); // Will initiate $sTemplateFolderName and $bHasTemplate. 76 self::$instance->setConfig(); 77 return self::$instance; 78 } 79 80 /** 81 * Get the current instance of template question object. |
#2 |
+
–
/var/www/html/application/helpers/qanda_helper.php(151): QuestionTemplate::getNewInstance(Question) 146 ,'input_error_class' => '' // provides a class. 147 ,'essentials' => '' 148 ); 149 150 $oQuestion = Question::model()->findByPk($ia[0]); 151 $oQuestionTemplate = QuestionTemplate::getNewInstance($oQuestion); 152 $oQuestionTemplate->registerAssets(); // Register the custom assets of the question template, if needed 153 $oRenderer = $oQuestion->getRenderererObject($ia); 154 $values = $oRenderer->render(); 155 156 |
#3 |
+
–
/var/www/html/application/helpers/SurveyRuntimeHelper.php(279): retrieveAnswers(array("1", "132339X1X1", "Q00Z", "A first example question. Please answer this question:", ...)) 274 } 275 276 //Get the answers/inputnames 277 // TMSW - can content of retrieveAnswers() be provided by LEM? Review scope of what it provides. 278 // TODO - retrieveAnswers is slow - queries database separately for each question. May be fixed in _CI or _YII ports, so ignore for now 279 list($plus_qanda, $plus_inputnames) = retrieveAnswers($ia); 280 281 if ($plus_qanda) { 282 $plus_qanda[] = $ia[4]; 283 $plus_qanda[] = $ia[6]; // adds madatory identifyer for adding mandatory class to question wrapping div 284 |
#4 |
+
–
/var/www/html/application/controllers/survey/index.php(610): SurveyRuntimeHelper->run("132339",
array("surveyid" => "132339", "thissurvey" => array("htmlemail"
=> "Y", "format" => "G", "tokenencryptionoptions" => "",
"template" => "fruity", ...), "thisstep" => "0", "tokensexist"
=> 0, ...)) 605 unset($redata); 606 $redata = compact(array_keys(get_defined_vars())); 607 Yii::import('application.helpers.SurveyRuntimeHelper'); 608 $tmp = new SurveyRuntimeHelper(); 609 // try { 610 $tmp->run($surveyid, $redata); 611 // } catch (WrongTemplateVersionException $ex) { 612 // echo $ex->getMessage(); 613 // } 614 } 615 |
#5 |
+
–
/var/www/html/application/controllers/survey/index.php(26): index->action() 21 public $oTemplate; 22 23 public function run() 24 { 25 useFirebug(); 26 $this->action(); 27 } 28 29 public function action() 30 { 31 global $surveyid; |
#6 |
+
–
/var/www/html/framework/web/actions/CAction.php(76): index->run() 71 { 72 $method=new ReflectionMethod($this, 'run'); 73 if($method->getNumberOfParameters()>0) 74 return $this->runWithParamsInternal($this, $method, $params); 75 76 $this->run(); 77 return true; 78 } 79 80 /** 81 * Executes a method of an object with the supplied named parameters. |
#7 |
+
–
/var/www/html/framework/web/CController.php(308): CAction->runWithParams(array("sid" => "132339")) 303 { 304 $priorAction=$this->_action; 305 $this->_action=$action; 306 if($this->beforeAction($action)) 307 { 308 if($action->runWithParams($this->getActionParams())===false) 309 $this->invalidActionParams($action); 310 else 311 $this->afterAction($action); 312 } 313 $this->_action=$priorAction; |
#8 |
+
–
/var/www/html/framework/web/CController.php(286): CController->runAction(index) 281 * @see runAction 282 */ 283 public function runActionWithFilters($action,$filters) 284 { 285 if(empty($filters)) 286 $this->runAction($action); 287 else 288 { 289 $priorAction=$this->_action; 290 $this->_action=$action; 291 CFilterChain::create($this,$action,$filters)->run(); |
#9 |
+
–
/var/www/html/framework/web/CController.php(265): CController->runActionWithFilters(index, array()) 260 { 261 if(($parent=$this->getModule())===null) 262 $parent=Yii::app(); 263 if($parent->beforeControllerAction($this,$action)) 264 { 265 $this->runActionWithFilters($action,$this->filters()); 266 $parent->afterControllerAction($this,$action); 267 } 268 } 269 else 270 $this->missingAction($actionID); |
#10 |
+
–
/var/www/html/framework/web/CWebApplication.php(282): CController->run("index") 277 { 278 list($controller,$actionID)=$ca; 279 $oldController=$this->_controller; 280 $this->_controller=$controller; 281 $controller->init(); 282 $controller->run($actionID); 283 $this->_controller=$oldController; 284 } 285 else 286 throw new CHttpException(404,Yii::t('yii','Unable to resolve the request "{route}".', 287 array('{route}'=>$route===''?$this->defaultController:$route))); |
#11 |
+
–
/var/www/html/framework/web/CWebApplication.php(141): CWebApplication->runController("survey/index/sid/132339") 136 foreach(array_splice($this->catchAllRequest,1) as $name=>$value) 137 $_GET[$name]=$value; 138 } 139 else 140 $route=$this->getUrlManager()->parseUrl($this->getRequest()); 141 $this->runController($route); 142 } 143 144 /** 145 * Registers the core application components. 146 * This method overrides the parent implementation by registering additional core components. |
#12 |
+
–
/var/www/html/framework/base/CApplication.php(185): CWebApplication->processRequest() 180 public function run() 181 { 182 if($this->hasEventHandler('onBeginRequest')) 183 $this->onBeginRequest(new CEvent($this)); 184 register_shutdown_function(array($this,'end'),0,false); 185 $this->processRequest(); 186 if($this->hasEventHandler('onEndRequest')) 187 $this->onEndRequest(new CEvent($this)); 188 } 189 190 /** |
#13 |
+
–
/var/www/html/index.php(192): CApplication->run() 187 require_once APPPATH . 'core/LSYii_Application' . EXT; 188 189 $config = require_once(APPPATH . 'config/internal' . EXT); 190 191 Yii::$enableIncludePath = false; 192 Yii::createApplication('LSYii_Application', $config)->run(); 193 194 /* End of file index.php */ 195 /* Location: ./index.php */ |