mirror of
https://github.com/phanan/htaccess.git
synced 2018-11-08 13:39:40 +01:00
Some minor rewording
This commit is contained in:
parent
e359543c9a
commit
38637cc493
1 changed files with 1 additions and 3 deletions
|
@ -122,9 +122,7 @@ RewriteRule ^(.*)/$ /$1 [R=301,L]
|
|||
```
|
||||
|
||||
### Remove Trailing Slash from Arbitrary Paths
|
||||
This snippet will redirect paths ending in slashes to their non-slash-terminated counterparts (except for actual directories).
|
||||
E.g., `http://www.example.com/blog/` -> `http://www.example.com/blog`
|
||||
This is important for SEO, since it is [recommended to have a "canonical URL" for every page](http://overit.com/blog/canonical-urls).
|
||||
This snippet will redirect paths ending in slashes to their non-slash-terminated counterparts (except for actual directories), e.g. `http://www.example.com/blog/` to `http://www.example.com/blog`. This is important for SEO, since it's [recommended](http://overit.com/blog/canonical-urls) to have a canonical URL for every page.
|
||||
``` apacheconf
|
||||
RewriteCond %{REQUEST_FILENAME} !-d
|
||||
RewriteCond %{REQUEST_URI} (.+)/$
|
||||
|
|
Loading…
Reference in a new issue