带有 .htaccess 和 moderewrite 的安全 URL

发布于 2024-08-24 03:44:33 字数 378 浏览 4 评论 0原文

嗨,伙计,这是我第一次来这里,我的英语很糟糕,抱歉...... 我的 .htaccess 有问题,我正在尝试使用以下代码重定向具有安全 url 的页面:

RewriteEngine On

RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^noticias/pagina/([0-9]+)/?$ news.php?id=$1 [NC,L]

但是我的 nes.php 调用的 swf 文件无法打开...

有人可以帮助我吗? 我可以解决这个问题吗?

我的 swf 文件与我的文件 news.php 位于同一文件夹中......

hi guy its my first time here and my english sukcs, sorry...
i have a problem with my .htaccess, i'm trying to redirect a page with a safe url using this code:

RewriteEngine On

RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^noticias/pagina/([0-9]+)/?$ news.php?id=$1 [NC,L]

but my swf files called by nes.php does not open...

can someone help me?
who can i fix this problem?

my swf file are in the same folder as my file news.php....

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

魔法少女 2024-08-31 03:44:33

这可能是由于错误引用您的资源而导致的问题。由于您现在使用不同的 URL (/noticias/pagina/...),因此现在从此基础解析相对 URL 路径,而不是旧的 (/news.php) )。引用 rodape.swf 现在已解析为 /noticias/pagina/rodape.swf

尝试使用绝对 URL 路径引用您的 SWF 文件:

<object type="application/x-shockwave-flash" data="/rodape.swf" width="960" height="45">

This is probably an issue with wrong references to your resources. Since you’re now using a different URL (/noticias/pagina/…), relative URL paths are now resolved from this base instead of your old (/news.php). A reference rodape.swf is now resolved to /noticias/pagina/rodape.swf.

Try to reference your SWF file with an absolute URL path:

<object type="application/x-shockwave-flash" data="/rodape.swf" width="960" height="45">
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文