Changeset 364 for trunk/Common/Module.php
- Timestamp:
- Jan 19, 2012, 7:30:34 AM (13 years ago)
- File:
-
- 1 moved
Legend:
- Unmodified
- Added
- Removed
-
trunk/Common/Module.php
r363 r364 1 1 <?php 2 2 3 include_once(dirname(__FILE__).'/ ../Model.php');3 include_once(dirname(__FILE__).'/Model.php'); 4 4 5 5 class Module … … 75 75 while($Module = $DbResult->fetch_array()) 76 76 { 77 include_once( dirname(__FILE__).'/'.$Module['Name'].'/'.$Module['Name'].'.php');77 include_once('Modules/'.$Module['Name'].'/'.$Module['Name'].'.php'); 78 78 $ModuleClassName = 'Module'.$Module['Name']; 79 79 $this->Modules[$Module['Name']] = new $ModuleClassName($this->Database, $this); … … 122 122 // Load list of modules on disk 123 123 $ModulesOnDisk = array(); 124 $Files = scandir( dirname(__FILE__));124 $Files = scandir('Modules'); 125 125 foreach($Files as $File) 126 if(is_dir( dirname(__FILE__).'/'.$File) and ($File != '.') and ($File != '..') and (substr($File, 0, 1) != '.'))126 if(is_dir('Modules/'.$File) and ($File != '.') and ($File != '..') and (substr($File, 0, 1) != '.')) 127 127 { 128 128 $ModulesOnDisk[] = $File; … … 134 134 { 135 135 DebugLog('Adding module '.$ModuleName.' to list'); 136 include_once( dirname(__FILE__).'/'.$ModuleName.'/'.$ModuleName.'.php');136 include_once('Modules/'.$ModuleName.'/'.$ModuleName.'.php'); 137 137 $ModuleClassName = 'Module'.$ModuleName; 138 138 if(class_exists($ModuleClassName))
Note:
See TracChangeset
for help on using the changeset viewer.