Zend Framework 1.9 and Doctrine Integration

前端 未结 4 892
故里飘歌
故里飘歌 2020-12-25 08:29

I\'m trying to setup Zend Framework and Doctrine.

There is this previous discussion with ZF 1.8

  • Integrate Doctrine with Zend Framework 1.8 app
相关标签:
4条回答
  • 2020-12-25 08:59

    Found a solution

    http://pastie.org/481635 http://pastie.org/481633

    Setup autoloader and plugin path in application/configs/application.ini:

    autoloadernamespaces.0 = "Doctrine"
    
    pluginpaths.ZendX_Doctrine_Application_Resource= "ZendX/Doctrine/Application/Resource"
    

    Add paths to models and generated models in public/index.php

    set_include_path(implode(PATH_SEPARATOR, array(
        realpath(APPLICATION_PATH . '/../library'),
        realpath(APPLICATION_PATH . '/models'),
        realpath(APPLICATION_PATH . '/models/generated'),
        get_include_path(),
    )));
    

    Save http://pastie.org/481633 to library/ZendX/Doctrine/Application/Resource/Doctrine.php

    0 讨论(0)
  • 2020-12-25 08:59

    I picked up a few pointers from the previously suggested entry by Mathew Weier O'Phinney, as well as entries from Danceric that were originally based on ZF 1.8:

    • Doctrine ORM and Zend Framework
      http://www.danceric.net/2009/06/06/doctrine-orm-and-zend-framework/
    • Doctrine 1.2 is Zend Framework friendly
      http://www.danceric.net/2009/10/29/doctrine-1-2-is-zend-framework-friendly/

    You may also be interested in the following links (a selection of my bookmarks matching "zend framework" and "doctrine"):

    • Integrating Zend Framework with Doctrine ORM
      http://roysimkes.net/blog/2009/11/integrating-zend-framework-with-doctrine-orm/
    • Integrating Zend Framework and Doctrine
      http://ruben.savanne.be/articles/integrating-zend-framework-and-doctrine
    • Optimizing Zend Framework and Doctrine applications
      http://codeutopia.net/blog/2009/01/17/optimizing-zend-framework-and-doctrine-applications/

    Apologies for the plain text links. I am a new user here and subject to strict spam prevention rules.

    0 讨论(0)
  • 2020-12-25 09:08

    I built up a ready to use frame for Zend 1.11.11 and Doctrine 2.0.7 development and hosted it under ZendDoctrineFrame. Feel free to use it!

    0 讨论(0)
  • 2020-12-25 09:13

    Matthew Weier O'Phinney has blogged about the issue

    0 讨论(0)
提交回复
热议问题