I have a rather complex problem (for me), which is why i need to turn to you guys :) Always heave been a great and fast ressource for help.
我有一个相当复杂的问题(对我而言),这就是为什么我需要求助于你们:)总是一直是一个伟大而快速的资源帮助。
Background: I have a website where the homepage is one big draggable screen (www.example.com/) where all the subpages are teasered. If you click on a Teaser (www.example.com/pages/page1) a jquery lightbox with iframe will open and present that page. That works great.
背景:我有一个网站,主页是一个大的可拖动屏幕(www.example.com/),其中所有的子页面都是teasered。如果您点击预告片(www.example.com/pages/page1),则会打开一个带有iframe的jquery灯箱并显示该页面。这很好用。
Problem: Problem is, as always have been with iframes, if someone goes to the subpage directly (www.example.com/pages/page1), maybe via an indexed google search, he will not see the iframe and the big draggable screen behind it.
问题:问题是,如果有人直接访问子页面(www.example.com/pages/page1),可能是通过索引的谷歌搜索,问题就像iframe一样,他不会看到iframe和背后的大拖动屏幕它。
Question: i'd need a script which, before anything happens, redirects an URL with more parts then root to the root page and append the parts as a different query, so i could read them out via javascript or something and trigger the iframelightbox per hand.
问题:我需要一个脚本,在发生任何事情之前,重定向一个带有更多部分的URL,然后将root重定向到根页面并将这些部分作为不同的查询附加,这样我就可以通过javascript或其他东西读取它们并触发iframelightbox手。
Approach: so
www.example.com/pages/page1
needs to become
需要成为
www.example.com?vars=/pages/page1
or something appropriate.
或适当的东西。
i think this is possible using mod_rewrite in my htaccess but i dont know how.
我认为这可以在我的htaccess中使用mod_rewrite,但我不知道如何。
I hope this it understandable in some way :) i tried my best.
我希望这在某种程度上可以理解:)我尽我所能。
3
RewriteRule ^(.+)$ /?vars=$1
Should do the trick.
应该做的伎俩。
Don't put an * instead of + or you may end in infinite loop.
不要放*而不是+或者你可以以无限循环结束。
本站翻译的文章,版权归属于本站,未经许可禁止转摘,转摘请注明本文地址:http://www.silva-art.net/blog/2011/04/19/c1603ffb80d3da7e8058ffa3957c8ba4.html。