[ Index ] |
|
Code source de LifeType 1.2.4 |
1 <?php 2 3 lt_include( PLOG_CLASS_PATH."class/view/admin/admintemplatedview.class.php" ); 4 lt_include( PLOG_CLASS_PATH."class/plugin/pluginmanager.class.php" ); 5 lt_include( PLOG_CLASS_PATH."class/plugin/globalpluginconfig.class.php" ); 6 7 class AdminPluginSettingsView extends AdminTemplatedView 8 { 9 var $_userInfo; 10 var $_setData; 11 12 function AdminPluginSettingsView( $blogInfo, $userInfo ) 13 { 14 $this->AdminTemplatedView( $blogInfo, "pluginsettings" ); 15 16 $this->_userInfo = $userInfo; 17 $this->_setData = true; 18 } 19 20 function setData( $set ) 21 { 22 $this->_setData = $set; 23 } 24 25 /** 26 * load the fields and pass them to the view 27 */ 28 function render() 29 { 30 // initialize the plugin manager and load the plugins 31 $pluginManager =& PluginManager::getPluginManager(); 32 33 // we need to get an array with the plugins 34 $pluginManager->refreshPluginList(); 35 $pluginManager->setBlogInfo( $this->_blogInfo ); 36 $pluginManager->setUserInfo( $this->_userInfo ); 37 $plugins = $pluginManager->getPlugins(); 38 39 // put the plugin objects in the template 40 $this->setValue( "plugins", $plugins ); 41 42 // load the settings unless we were configured not to 43 if( $this->_setData ) { 44 // plugin values 45 $values = GlobalPluginConfig::getValues(); 46 foreach( $values as $key => $value ) { 47 $this->setValue( $key, $value ); 48 } 49 // and override settings 50 $this->setValue( "canOverride", GlobalPluginConfig::getOverrideSettings()); 51 } 52 53 return( parent::render()); 54 } 55 } 56 ?>
titre
Description
Corps
titre
Description
Corps
titre
Description
Corps
titre
Corps
Généré le : Mon Nov 26 21:04:15 2007 | par Balluche grâce à PHPXref 0.7 |
![]() |