0

こんにちは、これは私の htaccess コードです

Options All -Indexes
ErrorDocument 404 /404.php
FileETag MTime Size

<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /lang/

RewriteRule ^sitemap\.xml$ index.php [L]
RewriteRule ^(.*)(\.html|\.htm)$ index.php [L]
RewriteRule ^(.*)(\.rss|\.atom|\.txt)$ index.php [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)/?$ index.php [L]
</IfModule>

<IfModule mod_expires.c>
    ExpiresActive on
    ExpiresByType image/gif "access plus 1 months"
    ExpiresByType image/jpeg "access plus 1 months"
    ExpiresByType image/png "access plus 1 months"
    ExpiresByType text/css "access plus 1 months"
    ExpiresByType application/x-javascript "access plus 1 months"
</IfModule>

私はこのお問い合わせフォームを持っています

http://www.example.com/lang/contact-se

ユーザーがフォームと連絡先を使用するとき

にリダイレクトします

http://www.example.com/lang/contact-se.html

エラーページが見つかりません

このリンクを書き換えからのみ除外し、.html にリダイレクトするにはどうすればよいですか

4

1 に答える 1

0

/lang/contact-seフォームをではなく に送信するように変更します/lang/contact-se.html

これがあなたのルールと何の関係があるのか​​わからない. contact-se と contact-se.html の両方がindex.php.

于 2012-10-06T09:47:42.890 に答える