Changeset 5546 for extensions/AStat/astat_aim.class.inc.php
- Timestamp:
- Apr 1, 2010, 9:04:16 PM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
extensions/AStat/astat_aim.class.inc.php
r5423 r5546 16 16 if (!defined('PHPWG_ROOT_PATH')) { die('Hacking attempt!'); } 17 17 18 include_once(PHPWG_PLUGINS_PATH.' grum_plugins_classes-2/common_plugin.class.inc.php');19 include_once(PHPWG_PLUGINS_PATH.' grum_plugins_classes-2/css.class.inc.php');20 21 class AStat_AIM extends common_plugin18 include_once(PHPWG_PLUGINS_PATH.'GrumPluginClasses/classes/CommonPlugin.class.inc.php'); 19 include_once(PHPWG_PLUGINS_PATH.'GrumPluginClasses/classes/GPCCss.class.inc.php'); 20 21 class AStat_AIM extends CommonPlugin 22 22 { 23 23 protected $css = null; … … 25 25 function AStat_AIM($prefixeTable, $filelocation) 26 26 { 27 $this-> plugin_name="AStat.2";28 $this-> plugin_name_files="astat";27 $this->setPluginName("AStat.2"); 28 $this->setPluginNameFiles("astat"); 29 29 parent::__construct($prefixeTable, $filelocation); 30 $this->css = new css(dirname($this->filelocation).'/'.$this->plugin_name_files.".css");30 $this->css = new GPCCss(dirname($this->getFileLocation()).'/'.$this->getPluginNameFiles().".css"); 31 31 } 32 32 … … 34 34 initialize events call for the plugin 35 35 */ 36 function init _events()37 { 38 add_event_handler('get_admin_plugin_menu_links', array(&$this, 'plugin _admin_menu') );36 function initEvents() 37 { 38 add_event_handler('get_admin_plugin_menu_links', array(&$this, 'pluginAdminMenu') ); 39 39 } 40 40 … … 43 43 initialization of config properties 44 44 */ 45 function init _config()46 { 47 $this-> my_config=array(45 function initConfig() 46 { 47 $this->config=array( 48 48 'AStat_BarColor_Pages' => '6666ff', 49 49 'AStat_BarColor_Img' => '66ff66', … … 69 69 70 70 /* 71 surchage of common_plugin->save_config function72 */ 73 function load _config()74 { 75 parent::load _config();76 if(!$this->css-> css_file_exists())77 { 78 $this->css->make _CSS($this->generate_CSS());79 } 80 } 81 82 /* 83 surchage of common_plugin->save_config function84 */ 85 function save _config()86 { 87 if(parent::save _config())88 { 89 $this->css->make _CSS($this->generate_CSS());71 surchage of CommonPlugin->saveConfig function 72 */ 73 function loadConfig() 74 { 75 parent::loadConfig(); 76 if(!$this->css->fileExists()) 77 { 78 $this->css->makeCSS($this->generate_CSS()); 79 } 80 } 81 82 /* 83 surchage of CommonPlugin->saveConfig function 84 */ 85 function saveConfig() 86 { 87 if(parent::saveConfig()) 88 { 89 $this->css->makeCSS($this->generate_CSS()); 90 90 return(true); 91 91 } … … 114 114 padding:0px; 115 115 } 116 .AStatBar1 { background-color:#".$this-> my_config['AStat_BarColor_Pages']."; top:5px; }117 .AStatBar2 { background-color:#".$this-> my_config['AStat_BarColor_Img']."; top:-3px; }118 .AStatBar3 { background-color:#".$this-> my_config['AStat_BarColor_IP']."; top:-3px;}119 .AStatBar4 { background-color:#".$this-> my_config['AStat_BarColor_Cat']."; top:-3px;}116 .AStatBar1 { background-color:#".$this->config['AStat_BarColor_Pages']."; top:5px; } 117 .AStatBar2 { background-color:#".$this->config['AStat_BarColor_Img']."; top:-3px; } 118 .AStatBar3 { background-color:#".$this->config['AStat_BarColor_IP']."; top:-3px;} 119 .AStatBar4 { background-color:#".$this->config['AStat_BarColor_Cat']."; top:-3px;} 120 120 .AStatBarX { background-color:transparent; top:-3px; height:1px; } 121 .MiniSquare1 { color:#".$this-> my_config['AStat_BarColor_Pages']."; }122 .MiniSquare2 { color:#".$this-> my_config['AStat_BarColor_Img']."; }123 .MiniSquare3 { color:#".$this-> my_config['AStat_BarColor_IP']."; }124 .MiniSquare4 { color:#".$this-> my_config['AStat_BarColor_Cat']."; }125 .StatTableRow:hover { background-color:#".$this-> my_config['AStat_MouseOverColor']."; }121 .MiniSquare1 { color:#".$this->config['AStat_BarColor_Pages']."; } 122 .MiniSquare2 { color:#".$this->config['AStat_BarColor_Img']."; } 123 .MiniSquare3 { color:#".$this->config['AStat_BarColor_IP']."; } 124 .MiniSquare4 { color:#".$this->config['AStat_BarColor_Cat']."; } 125 .StatTableRow:hover { background-color:#".$this->config['AStat_MouseOverColor']."; } 126 126 .formtable, .formtable P { text-align:left; display:block; } 127 127 .formtable tr { vertical-align:top; }
Note: See TracChangeset
for help on using the changeset viewer.