我試圖做一個靜態網站b2evolution這個wget的行:改寫....到index.php%3F .... HTML
wget -nv -b -m -k -p -E -erobots=off --tries=5 --exclude-directories=calendar,users,user --domains directory http://site.com
它產生類似的文件這樣的:
index.php?blog=2&cat=21.html
試圖訪問這個網址在:
http://site.com/index.php?blog=2&cat=21.html
我recive瀏覽器的這個錯誤:
Not Found
The requested URL /index.php was not found on this server.
,這在error.log中:
[Mon Feb 10 19:02:49 2013] [error] [client xx.xx.xx.xx] script '/var/www/site.com/htdocs/index.php' not found or unable to stat, referer: http://site.com/index.php
但我可以訪問使用%3F代替 '?':
http://site.com/index.php%3Fblog=2&cat=21.html
我的範圍允許訪問該網站與舊使用apache rewrite_mod修改'?'的url類型(帶'?') '%3F'。我已經tryed有:
RewriteRule ^index.php\? index.php\%3F [QSA,NE]
但我recive在日誌中的錯誤:
Request exceeded the limit of 10 internal redirects due to probable configuration error. Use 'LimitInternalRecursion' to increase the limit if necessary. Use 'LogLevel debug' to get a backtrace.
任何想法與mod_rewrite的或與他人wget的參數來解決?
It作品。讓我來看看Cond吧,你會得到任何帶有0個或更多字符的查詢,以後我們可以使用%i(在這種情況下i = 1)。比你在(1)$ arg之間捕獲。內部的點必須受到保護,因爲它意味着任何字符。最後,我們告訴mod_rewrite如何轉換recived url。 – jedi 2013-02-11 20:06:42
幾乎正確。我編輯了我的答案。 – 2013-02-11 20:20:43
準確得多! TNX。 – jedi 2013-02-11 21:59:51