duanqizao6492 2015-10-26 15:46
浏览 68
已采纳

如何在带有wamp或ampps的windows中安装和运行propel2

I would like to use propel 2, using the .zip file in windows but I can't make it work according the docs1 (I use wamp and ampps, different servers) so I unzipped the file inside my WWW folder in my (wamp) server
I try to call http://server/test/propel/bin/propel.php and i get a 500 error page; watching the php log file I see:

  • PHP Fatal error: Class 'Symfony\Component\Finder\Finder' not found in ...\bin\propel.php on line 16
  • PHP Stack trace:
  • PHP 1. {main}() ...\propel.php:0

then i tried use the command line; and I set the PHPBIN variable to my php folder ('cause that one didn't exists in my environment) run the propel.bat and I get:

..\php5.5 is not reconigzed as a internal or external command ...

but then the docs didn't mention how to proceed afterwards for configure the connection

please, did anybody try this? what should I do??

thanks in advance!

  • 写回答

1条回答 默认 最新

  • doufu1950 2015-10-27 13:39
    关注

    Did you install it via composer? It's heavily recommanded as propel2 have a lot of dependancies, and it's a kinda complicated setup. http://propelorm.org/documentation/01-installation.html#via-composer https://getcomposer.org/doc/00-intro.md

    Anyway, once installed (in your project, you have a vendor/bin/propel file), open console in your project root directory and use :

    vendor\bin\propel init
    vendor\bin\propel sql:build
    

    I guess without composer, you have no bin in your vendor folder. If so, and you installed it via zip, you might need to go to folder vendor/propel directly and then in console :

    bin\propel init
    bin\propel sql:build
    

    Good luck, I remember not figuring it out right away either despite using composer.

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?