[英]How to add rewrite in bitnami site
我创建了一个新的bitnami网站,并为某些页面添加了一些重写规则。 除了一个链接(相机详细信息链接)以外,所有页面均正常运行。
相机列表页面链接按预期工作正常
http://{site-domain}/public/cameras
但是详细链接不起作用
http://{site-domain}/public/cameras/ruthin-school
我对详细信息页面使用以下规则:
<rule name="Show public camera details" stopProcessing="true">
<match url="^/?public/cameras/([^/]+)$" ignoreCase="true" />
<conditions logicalGrouping="MatchAll">
<add input="{REQUEST_FILENAME}" matchType="IsDirectory" negate="true" />
<add input="{REQUEST_FILENAME}" matchType="IsFile" negate="true" />
</conditions>
<action type="Rewrite" url="/public/cameras/index.php?{R:1}" />
</rule>
有什么想法吗?
Bitnami开发人员在这里。
也许这不起作用,因为Apache是重定向到其他页面的人,因此,我强烈建议您将配置移到/opt/bitnami/apps/wordpress/conf/htaccess.conf
文件中。
这是有关编写apache规则的指南,与您现在使用的规则非常相似: http : //httpd.apache.org/docs/current/mod/mod_rewrite.html
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.