CHttpException

We are sorry but you don't have permissions to do this.

/var/www/essayshark.com/public_html/survey/application/controllers/survey/index.php(242)

230         if ($this->_surveyCantBeViewedWithCurrentPreviewAccess($surveyid, $isSurveyActive, $surveyExists)) {
231             $bPreviewRight = $this->_userHasPreviewAccessSession($surveyid);
232 
233             if ($bPreviewRight === false) {
234                 $event    = new PluginEvent('onSurveyDenied');
235                 $event->set('surveyId', $surveyid);
236                 $event->set('reason', 'noPreviewPermission');
237 
238                 App()->getPluginManager()->dispatchEvent($event);
239                 if(Permission::getUserId()) {
240                     throw new CHttpException(403, gT("We are sorry but you don't have permissions to do this.",'unescaped'));
241                 }
242                 throw new CHttpException(401, gT("We are sorry but you don't have permissions to do this.",'unescaped'));
243             }
244         }
245 
246         // TODO can this be moved to the top?
247         // (Used to be global, used in ExpressionManager, merged into amVars. If not filled in === '')
248         // can this be added in the first computation of $redata?
249         if (isset($_SESSION['survey_'.$surveyid]['srid'])) {
250             $saved_id = $_SESSION['survey_'.$surveyid]['srid'];
251         }
252 
253         // recompute $redata since $saved_id used to be a global
254         $redata = compact(array_keys(get_defined_vars()));

Stack Trace

#0
+
 /var/www/essayshark.com/public_html/survey/application/controllers/survey/index.php(24): index->action()
19     public $oTemplate;
20 
21     public function run()
22     {
23         useFirebug();
24         $this->action();
25     }
26 
27     public function action()
28     {
29         global $surveyid;
#8
+
 /var/www/essayshark.com/public_html/survey/index.php(195): CApplication->run()
190 require_once APPPATH . 'core/LSYii_Application' . EXT;
191 
192 $config = require_once(APPPATH . 'config/internal' . EXT);
193 
194 Yii::$enableIncludePath = false;
195 Yii::createApplication('LSYii_Application', $config)->run();
196 
197 /* End of file index.php */
198 /* Location: ./index.php */
2024-03-19 02:43:01 nginx/1.21.6 Yii Framework/1.1.26