.htaccess

    0熱度

    1回答

    我有這個問題,我用我的網址是這樣的: 如果有人從轉診有類似https://myweb.site/UERHF723R來的網站,所以我的htaccess有這樣的: RewriteRule ^([A-Za-z0-9-]+)/?$ index.php?ref=$1 [L,QSA] 但我怎麼可以發送給https://myweb.site/foldername而不發送給index.php作爲變量。 我想我可以

    0熱度

    1回答

    我安裝的WordPress上的/ var/vwww /從blog.example.net 訪問博客這工作得很好,完美 然後,我也喜歡它是從WWW訪問。 example.net/blog 至於結果,首先,我修改我的Apache虛擬主機條目做別名: <VirtualHost *:80> DocumentRoot /var/www/public_html Alias /blog /var/vwww

    0熱度

    1回答

    我的根目錄有以下文件夾和文件: private.txt public.txt private public 404.html 我想設置的方式,當用戶試圖訪問 domain.com/private.txt,他將被重定向到一個的.htaccess domain.com/404.html(404狀態),但如果用戶訪問 domain.com/public.txt,則不會發生重定向。我如何設置?

    0熱度

    1回答

    使用htaccess我如何301重定向以下? domain.com/index.php?r=apiv2/*到app.domain.com/index.php?r=apiv2/* 哪裏*是什麼 通配符這是迄今爲止我嘗試:提前 RewriteCond %{QUERY_STRING} r=apiv2(.*) RewriteRule ^index\.php$ https://app.domain.com

    0熱度

    1回答

    Yii2找不到資產。 設置從地址/前端/網站轉發到站點的根目錄。 .htaccets <IfModule mod_rewrite.c> Options +FollowSymlinks RewriteEngine On RewriteBase/ RewriteCond %{REQUEST_URI} ^/(admin) RewriteRule ^adm

    0熱度

    1回答

    如何在.htaccess中優化重定向301,而不是爲不同的語言編寫3次!謝謝! ([] =) Redirect 301 /ru/category/1269-name-tovar.html https://site[.]com/category Redirect 301 /en/category/1269-name-tovar.html https://site[.]com/category R

    0熱度

    1回答

    我的網址還http://test.com//123.html 注意到它//從第三方是不是我的控制下,所以我要趕// URL和重定向到單個斜線。我有這個在我的.htaccess RewriteCond %{REQUEST_URI} ^(.*)//(.*)$<br> RewriteRule . %1/%2 [R=301,L] 然而,它不工作,我看到仍然/ /在瀏覽器中。我的代碼有問題嗎?

    -3熱度

    1回答

    我怎麼能改寫這樣的URL: example.com/page.php?link=Anythingelse to example.com/Anythingelse and using <h1><?php echo $link; ?></h1> 這與內容PHP: 輸出示例:網站-Title:Anythingelse - 網站標題和標題1 Anythingelse 第一個想法是: Rewrit

    1熱度

    1回答

    基於重寫目錄我有一個文件夾export可訪問我的所有子域: /export/sub1/... /export/sub2/... /export/sub3/... 眼下,不管是什麼子域你,你可以通過改變看到的所有內容目錄中的網址。 這不是一個安全問題,但更多的是標準化的關注,但我想用.htaccess文件改寫文件夾,以便人們看到,他們的子域匹配了經修改的路徑: sub1.domain.tld

    1熱度

    1回答

    我想阻止通過重定向在.htaccess以下URL 403或301重定向到網站的網址 https://www.sitename.com/a/manage_blog https://www.sitename.com/index.php/a/manage_blog 在.htaccess ,我寫就像 RewriteRule ^(index.php/?)?a/manage_blog - [L,R=403]