Skip to content

Instantly share code, notes, and snippets.

@MichaelGooden
Created August 14, 2013 09:00
Show Gist options
  • Save MichaelGooden/6229196 to your computer and use it in GitHub Desktop.
Save MichaelGooden/6229196 to your computer and use it in GitHub Desktop.
//Module.php
<?php
namespace VendorName\LibraryName;
class Module
{
public function getAutoloaderConfig()
{
return array(
'Zend\Loader\StandardAutoloader' => array(
'namespaces' => array(
__NAMESPACE__ => __DIR__ . '/src/' . __NAMESPACE__,
),
),
);
}
}
Have your directory structure like this:
VendorName\LibraryName:
Module.php
src\VendorName\LibraryName:
your files.
MyClass.php (which would be namespaced as VendorName\LibraryName\MyClass)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment