.htaccess

    2熱度

    1回答

    重定向我已經設置了301重定向下面將重定向/作業重定向子文件夾下面的所有子頁面,當用戶瀏覽到 https://www.main-domain.com/jobs/ RedirectMatch 301 /jobs/.* https://www.main-domain.com/all-vacancies/ 我問題出現了,因爲我在「main-domain.com」的子目錄中有一個子站點,它也使用當我想

    1熱度

    2回答

    我試圖完成兩件事情與htaccess文件: 強制使用HTTPS上的所有,但2個目錄,只有從PROD訪問的URL(沒有上開發HTTPS) 在index.php文件重定向任何不存在的URL 這是我有: RewriteEngine On # Redirect all http to https RewriteCond %{HTTPS} !=on RewriteCond %{HTTP_HOST} m

    0熱度

    1回答

    我知道類似的問題已經被問到,但這個相同的代碼在兩個網站上工作,並沒有三分之一,所以我正在尋找想要改變和/或者要弄清楚爲什麼它不能在第三個網站上工作。 什麼需要發生:重定向域(1)非https的所有請求到https,以及(2)所有非www到www ...除staging.___.com子域以外的所有請求,它既不會收到www,也不會收到https。 #Rewrite http to https Re

    1熱度

    2回答

    我需要一個域來管理語言(en/it/pt/es)以及刪除www。和力HTTPS RewriteEngine On # -> www.example.com to example.com RewriteCond %{HTTP_HOST} www.example.com RewriteRule (.*) http://example.com/$1 [L,R=3

    0熱度

    1回答

    我需要得到一個文件誰是另一個目錄 例如/app/uploads/file.apk 我需要它/file/demo/file.apk 哪個規則,我需要使用? RewriteRule ^file/([A-Za-z0-9_-]+)/([A-Za-z0-9_-]+).([^/.]+)$file/viewfile.php?user=$1&name=$2 [QSA,L]

    0熱度

    1回答

    我的Hoster允許多個網站,但只有一個DocumentRoot適用於所有域。 我想什麼是網站與不同的內容: https://www.site1.com https://www.site2.com 我有什麼: Directory Structure /html/ <- Document root /html/site1.com/ <- Symlink to /pages/site1.co

    0熱度

    1回答

    我在我的htaccess文件以下行... RewriteRule ^poolpage.php?poolid=9f30d1c77b91aca6318d179ad5df2b7 /poolpage.php?poolid=9f30d1c77b91aca6318d179ad5df2b7a [NC,L] RewriteRule ^poolpage.php?poolid=c4899d49e0a26b47bb5

    1熱度

    1回答

    我剛剛上傳了一個重新設計和開發的WP網站,我想知道如何自動更新舊網址。我不確定這是否應該是一個手動過程,因爲我對WP仍然很陌生。下面是我的URL結構的例子: 舊網站: http://example.com/service-page-here/ 新建站點: http://example.com/services/service-page-here/

    1熱度

    1回答

    使用mod_rewrite 2個GET參數需要從舊的URL重寫: example.com/search?search_query=SOMEQUERY&search_type=videos&type=public 到 example.com/search/videos?search_query=SOMEQUERY&type=public

    0熱度

    2回答

    我想檢查所有請求的url,如果url中包含「video」文件夾,將其重定向到一個API文件。那麼API給我一個只包含「respond:true」或「respond:false」的json文件。如果在json文件中有迴應:true必須顯示url,並且如果json文件包含respond:false,則必須向用戶顯示預定義的簡單403頁面。 我知道拳頭的一部分,可以在.htaccess文件中一個簡單的代