Skip to content

Commit 977200b

Browse files
authored
Update securing-modx.md - add 404 page in .htaccess (#529)
add 404 page in .htaccess
1 parent a331266 commit 977200b

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

en/getting-started/maintenance/securing-modx.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,12 @@ RewriteCond %{HTTP_HOST} ^(www\.)?example\.com$ [NC]
3434
RewriteRule ^(\.(?!well_known)|_build|_gitify|_backup|core|config.core.php) /index.php?q=doesnotexist [L,R=404]
3535
```
3636

37+
To show your error page, you need to specify the path to it in .htaccess, for example:
38+
39+
```
40+
ErrorDocument 404 /404
41+
```
42+
3743
For NGINX, add the following to your web rules which will pass the rewrites to the MODX error handler:
3844

3945
```

0 commit comments

Comments
 (0)