/mnt/data/shnoulle/nginx/www/3LTS/application/models/TemplateManifest.php(860)
848 * @param string $sDate The wanted date, if empty the current date with config time adjustment will be used 849 */ 850 public static function changeDateInDOM($oNewManifest, $sDate = '') 851 { 852 $date = (empty($date)) ?dateShift(date("Y-m-d H:i:s"), "Y-m-d H:i", Yii::app()->getConfig("timeadjust")) : $date; 853 $oConfig = $oNewManifest->getElementsByTagName('config')->item(0); 854 $ometadata = $oConfig->getElementsByTagName('metadata')->item(0); 855 $oOldDateNode = $ometadata->getElementsByTagName('creationDate')->item(0); 856 $oNvDateNode = $oNewManifest->createElement('creationDate', $sDate); 857 $ometadata->replaceChild($oNvDateNode, $oOldDateNode); 858 $oOldUpdateNode = $ometadata->getElementsByTagName('last_update')->item(0); 859 $oNvDateNode = $oNewManifest->createElement('last_update', $sDate); 860 $ometadata->replaceChild($oNvDateNode, $oOldUpdateNode); 861 } 862 863 /** 864 * Change the template name inside the manifest (called from template editor) 865 * NOTE: all tests (like template exist, etc) are done from template controller. 866 * 867 * @param string $sOldName The old name of the template 868 * @param string $sNewName The newname of the template 869 */ 870 public static function rename($sOldName, $sNewName) 871 { 872 libxml_disable_entity_loader(false);
#0 |
+
–
/mnt/data/shnoulle/nginx/www/3LTS/application/models/TemplateManifest.php(860): DOMNode->replaceChild(DOMElement, null) 855 $oOldDateNode = $ometadata->getElementsByTagName('creationDate')->item(0); 856 $oNvDateNode = $oNewManifest->createElement('creationDate', $sDate); 857 $ometadata->replaceChild($oNvDateNode, $oOldDateNode); 858 $oOldUpdateNode = $ometadata->getElementsByTagName('last_update')->item(0); 859 $oNvDateNode = $oNewManifest->createElement('last_update', $sDate); 860 $ometadata->replaceChild($oNvDateNode, $oOldUpdateNode); 861 } 862 863 /** 864 * Change the template name inside the manifest (called from template editor) 865 * NOTE: all tests (like template exist, etc) are done from template controller. |
#1 |
+
–
/mnt/data/shnoulle/nginx/www/3LTS/application/models/TemplateManifest.php(979): TemplateManifest::changeDateInDOM(DOMDocument) 974 libxml_disable_entity_loader(false); 975 $oNewManifest = self::getManifestDOM($sConfigPath); 976 977 self::deleteEngineInDom($oNewManifest); 978 self::changeNameInDOM($oNewManifest, $sNewName); 979 self::changeDateInDOM($oNewManifest); 980 self::changeAuthorInDom($oNewManifest); 981 self::changeEmailInDom($oNewManifest); 982 self::changeExtendsInDom($oNewManifest, $sToExtends); 983 984 $oNewManifest->save($sConfigPath."/config.xml"); |
#2 |
+
–
/mnt/data/shnoulle/nginx/www/3LTS/application/controllers/admin/themes.php(576): TemplateManifest::extendsConfig("skelvanilla", "extends_skelvanilla") 571 572 if ($mkdirresult == 1) { 573 // We just copy the while directory structure, but only the xml file 574 $oFileHelper->copyDirectory($copydirname, $newdirname, array('fileTypes' => array('xml', 'png', 'jpg'), 'newDirMode' => 0755)); 575 //TemplateConfiguration::removeAllNodes($newdirname); 576 TemplateManifest::extendsConfig($copydir, $newname); 577 TemplateManifest::importManifest($newname, ['extends' => $copydir]); 578 $this->getController()->redirect(array("admin/themes/sa/view", 'templatename'=>$newname)); 579 } elseif ($mkdirresult == 2) { 580 Yii::app()->setFlashMessage(sprintf(gT("Directory with the name `%s` already exists - choose another name"), $newname), 'error'); 581 $this->getController()->redirect(array("admin/themes/sa/view", 'templatename'=>$copydir)); |
#3 |
unknown(0): themes->templatecopy()
|
#4 |
+
–
/mnt/data/shnoulle/nginx/www/3LTS/framework/web/actions/CAction.php(109): ReflectionMethod->invokeArgs(themes, array()) 104 elseif($param->isDefaultValueAvailable()) 105 $ps[]=$param->getDefaultValue(); 106 else 107 return false; 108 } 109 $method->invokeArgs($object,$ps); 110 return true; 111 } 112 } |
#5 |
+
–
/mnt/data/shnoulle/nginx/www/3LTS/application/core/Survey_Common_Action.php(83): CAction->runWithParamsInternal(themes,
ReflectionMethod, array("r" => "admin/themes/sa/templatecopy", "sa"
=> "templatecopy", "sAction" => "templatecopy")) 78 $oMethod = new ReflectionMethod($this, $sDefault); 79 } 80 81 // We're all good to go, let's execute it 82 // runWithParamsInternal would automatically get the parameters of the method and populate them as required with the params 83 return parent::runWithParamsInternal($this, $oMethod, $params); 84 } 85 86 /** 87 * Some functions have different parameters, which are just an alias of the 88 * usual parameters we're getting in the url. This function just populates |
#6 |
+
–
/mnt/data/shnoulle/nginx/www/3LTS/application/controllers/admin/themes.php(33): Survey_Common_Action->runWithParams(array("r" => "admin/themes/sa/templatecopy", "sa" => "templatecopy", "sAction" => "templatecopy")) 28 public function runWithParams($params) 29 { 30 31 $sTemplateName = Yii::app()->request->getPost('templatename', ''); 32 if (Permission::model()->hasGlobalPermission('templates', 'read') || Permission::model()->hasTemplatePermission($sTemplateName)) { 33 parent::runWithParams($params); 34 } else { 35 Yii::app()->setFlashMessage(gT("We are sorry but you don't have permissions to do this."), 'error'); 36 $this->getController()->redirect(array("admin/themeoptions")); 37 } 38 } |
#7 |
+
–
/mnt/data/shnoulle/nginx/www/3LTS/framework/web/CController.php(308): themes->runWithParams(array("r" => "admin/themes/sa/templatecopy", "sa" => "templatecopy")) 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 |
+
–
/mnt/data/shnoulle/nginx/www/3LTS/framework/web/CController.php(286): CController->runAction(themes) 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 |
+
–
/mnt/data/shnoulle/nginx/www/3LTS/framework/web/CController.php(265): CController->runActionWithFilters(themes, 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 |
+
–
/mnt/data/shnoulle/nginx/www/3LTS/application/controllers/AdminController.php(165): CController->run("themes") 160 $this->redirect(array('/admin/authentication/sa/login')); 161 } 162 } 163 } 164 165 return parent::run($action); 166 } 167 168 /** 169 * Routes all the actions to their respective places 170 * |
#11 |
+
–
/mnt/data/shnoulle/nginx/www/3LTS/framework/web/CWebApplication.php(282): AdminController->run("themes") 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))); |
#12 |
+
–
/mnt/data/shnoulle/nginx/www/3LTS/framework/web/CWebApplication.php(141): CWebApplication->runController("admin/themes/sa/templatecopy") 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. |
#13 |
+
–
/mnt/data/shnoulle/nginx/www/3LTS/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 /** |
#14 |
+
–
/mnt/data/shnoulle/nginx/www/3LTS/index.php(194): CApplication->run() 189 require_once APPPATH . 'core/LSYii_Application' . EXT; 190 191 $config = require_once(APPPATH . 'config/internal' . EXT); 192 193 Yii::$enableIncludePath = false; 194 Yii::createApplication('LSYii_Application', $config)->run(); 195 196 /* End of file index.php */ 197 /* Location: ./index.php */ |