Guest User

Untitled

a guest
Jan 20th, 2019
78
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.81 KB | None | 0 0
  1. <?php
  2. namespace Album;
  3.  
  4. use Album\Model\AlbumTable;
  5. /**
  6. * Test class for Zend
  7. */
  8. class Album
  9. {
  10.  
  11.     function getAutoLoaderConfig()
  12.     {
  13.         return array(
  14.                 'Zend\Loader\ClassMapAutoloader' => array(
  15.                         __DIR__ . '/autoload_classmap.php',
  16.                     ),
  17.                 'Zend/Loader/StandartAutoloader' => array(
  18.                     'namespaces' => array(
  19.                         __NAMESPACE__ => __DIR__. '/src/'. __NAMESPACE__,
  20.                         ),
  21.                     ),
  22.             );
  23.     }
  24.  
  25.  
  26.  
  27.     public function getConfig()
  28.     {
  29.         return include __DIR__ . '/config/module.config.php';
  30.     }
  31.     public function getServiceConfig()
  32.     {
  33.         return array(
  34.             'factories'=>array(
  35.                 'Album\Model\AlbumTable' => function($m){
  36.                     $dbAdapter = $m->get('Zend\Db\Adapter\Adapter');
  37.                     $table     = new AlbumTable($dbAdapter);
  38.                     return $table;
  39.                 },
  40.             ),
  41.         );
  42.     }
  43. }
  44.  
  45.  
  46.  
  47.  
  48.  
  49.  
  50.  
  51.  
  52.  
  53.  
  54.  
  55.  
  56.  
  57. ?>
Add Comment
Please, Sign In to add comment