Changeset 12952
- Timestamp:
- 11/12/08 15:34:57 (8 months ago)
- Files:
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
branches/1.2/lib/config/sfProjectConfiguration.class.php
r12672 r12952 82 82 foreach ($this->getPluginPaths() as $path) 83 83 { 84 $name = basename($path); 85 $class = $name.'Configuration'; 86 87 if (is_readable($file = sprintf('%s/config/%sConfiguration.class.php', $path, $name))) 84 if (false === $plugin = array_search($path, $this->overriddenPluginPaths)) 85 { 86 $plugin = basename($path); 87 } 88 $class = $plugin.'Configuration'; 89 90 if (is_readable($file = sprintf('%s/config/%s.class.php', $path, $class))) 88 91 { 89 92 require_once $file; … … 95 98 } 96 99 97 $this->pluginConfigurations[$ name] = $configuration;100 $this->pluginConfigurations[$plugin] = $configuration; 98 101 } 99 102 … … 372 375 373 376 $this->plugins = array(); 374 foreach ($this->getAllPluginPaths() as $plugin )375 { 376 $this->plugins[] = basename($plugin);377 foreach ($this->getAllPluginPaths() as $plugin => $path) 378 { 379 $this->plugins[] = $plugin; 377 380 } 378 381 … … 480 483 * This method can be used to ease functional testing of plugins. It is not 481 484 * intended to support sharing plugins between projects, as many plugins 482 * save project specific code (to /lib/form , for example).485 * save project specific code (to /lib/form/base, for example). 483 486 * 484 487 * @param string $plugin … … 487 490 public function setPluginPath($plugin, $path) 488 491 { 489 $this->overriddenPluginPaths[$plugin] = $path;492 $this->overriddenPluginPaths[$plugin] = realpath($path); 490 493 } 491 494

