WAMP 别名的 mod_rewrite 吗?
我正在将 WAMPServer2 用于我的 php 框架 Nette。
我首先将其文件夹直接复制到WAMP的www文件夹中。我启用了 mod_rewrite 模块,并且设置了每个AllowOverride All。一切都运转良好。
我的问题是,因为多个项目,我为同一个项目创建了别名。现在,Nette 框架内的路由不起作用,因为 mod_rewrite 不起作用。我相信别名有一些额外的设置。我试图找到一些东西,但没有成功。我对修改 apache 设置的经验很少。有办法让它发挥作用吗?谢谢。
I am using WAMPServer2 for my php framework Nette.
I first copied its folder directly into www folder of WAMP. I enabled mod_rewrite module, and I have set every AllowOverride All. Everything functioned perfectly.
My problme is, than, becouse multiple project, I created alias for same project. Now, routing inside Nette framework doesent work, becouse mod_rewrite doesent. I believe there is some extra setting for Aliases. I tried to found something, but unsuccesfully. I have only little experience with modyfying apache settings. Is there a way to get it working? Thanks.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
今天我在 WAMP 中遇到了 mod_rewrite 和别名目录的问题。解决办法是在alias目录的.htaccess中设置RewriteBase。
解决办法是设置
I had trouble with this mod_rewrite and an alias directory in WAMP today. The solution was to set RewriteBase in the .htaccess of the alias directory.
The solution is to set
这可能是一个老问题,但我的解决方案如下:
我不想使用 .htaccess RewriteBase 进行管理,因为在生产环境中使用了相同的文件,而 RewriteBase 需要更改。
我没有创建 Apache 别名,而是创建了 Windows 符号链接。
我没有使用 Apache 指令,而是
转到当前的 webroot 目录并 createad
并且不需要更改任何其他配置(我不确定哪个目录路径具有权限)。
This might be an old question, but my solution was as follows:
I didn't want to mange with .htaccess RewriteBase since the same file was used in production environment, where RewriteBase would need to be changed.
Instead of creating Apache alias I created a Windows symbolic link.
Instead of Apache directive
I went to current webroot dir and createad
And don't need to change any other configuration (I am not sure in which directory path fall permissions).