1

我刚刚在 Amazon EC2 AMI Linux 上设置了 symfony 1.4。

每件事似乎都配置得很好,但是当我打开默认的 h*tp://ec2-xxxxxxx-.amazonaws.com/ URL 时,它显示给我401 | Unauthorized | InvalidArgumentException,错误是:

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.

任何帮助表示赞赏。

<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>
4

1 回答 1

0

好吧,这里的配置更错误。在您的数据库连接中添加密码或至少“:” i18n.yml

database: mysql://user:pass@localhost/db
database: mysql://user:@localhost/db

顺便说一句,您的索引也有问题:

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

另外,不要忘记添加别名以/sf在工具栏中显示图标:

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>
于 2012-04-18T07:16:47.920 回答