function _MYMODULE_autoload in X Autoload 7
Same name and namespace in other branches
- 7.5 xautoload.emulate.inc \_MYMODULE_autoload()
- 7.2 xautoload.emulate.inc \_MYMODULE_autoload()
- 7.3 xautoload.emulate.inc \_MYMODULE_autoload()
- 7.4 xautoload.emulate.inc \_MYMODULE_autoload()
The autoload callback for this specific module, used if xautoload is not present. You want to replace any "MYMODULE" with the module name.
1 string reference to '_MYMODULE_autoload'
- _MYMODULE_include in ./
xautoload.emulate.inc - Include basic files, and get the autoload to work.
File
- ./
xautoload.emulate.inc, line 33 - xautoload.emulate.inc
Code
function _MYMODULE_autoload($name) {
if (preg_match('#^MYMODULE_(.*)$#', $name, $m)) {
$path = strtr($m[1], '_', '/');
module_load_include('php', 'MYMODULE', "lib/{$path}");
}
}