重定向到新站点,除非位于指定目录中
我经营一个图像托管网站。让我们先了解以下信息。
Site: imagehosting.com
Tiny: imgho.st
Directory: n/
目录是图像的存储位置。无论如何。我正在尝试找出一种 apache 重写方法来将 imgho.st 重定向到 imagehosting.com 除非在 n/ 目录中。所以除非用户是imgho.st/n/83md.png重定向到imagehosting.com。
有人可以帮我解决这个问题吗?
谢谢!
I run an image hosting site. Lets just go with the following information.
Site: imagehosting.com
Tiny: imgho.st
Directory: n/
Directory is where the images are stored. Anyways. I'm trying to figure out an apache rewrite method to redirect imgho.st to imagehosting.com UNLESS in the n/ directory. So unless the user is imgho.st/n/83md.png redirect to imagehosting.com.
Could anybody help me out with this?
Thanks!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您可以将
RewriteCond
放在RewriteRule
之前You can put
RewriteCond
before yourRewriteRule