问题
I have just setup symfony 1.4 on Amazon EC2 AMI Linux.
Every thing seems to be configured fine but when I open the default h*tp://ec2-xxxxxxx-.amazonaws.com/ URL it shows me 401 | Unauthorized | InvalidArgumentException
and the error is:
Unable to load "cacheHelper.php" helper in: SF_ROOT_DIR/apps/frontend/lib/helper, SF_ROOT_DIR/lib/helper, SF_ROOT_DIR/lib/vendor/symfony/lib/helper.
Any help is appreciated.
<VirtualHost *:80>
ServerName ec2-184-73-90-216.compute-1.amazonaws.com
DocumentRoot "/var/www/html/project/web"
DirectoryIndex index.php
<Directory "/var/www/html/project/web">
AllowOverride All
Allow from All
</Directory>
</VirtualHost>
回答1:
Well it's more a wrong configuration here. Add a password or at least ":" in your database connection in the i18n.yml
:
database: mysql://user:pass@localhost/db
database: mysql://user:@localhost/db
And by the way, you also have something wrong in your index:
Fatal error: Call to a member function getId() on a non-object in /var/www/html/project/apps/frontend/modules/user/actions/actions.class.php on line 41
Also, don't forget to add an Alias to /sf
to have icon in the toolbar:
Alias /sf /var/www/html/project/lib/vendor/symfony/data/web/sf
<Directory "/var/www/html/project/lib/vendor/symfony/data/web/sf">
AllowOverride All
Allow from All
</Directory>
来源:https://stackoverflow.com/questions/10203669/symfony-1-4-unable-to-load-cachehelper-php