This repository was archived by the owner on Dec 12, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 7
mod_rewrite rules in htaccess
Sven Seeberg edited this page Feb 1, 2019
·
5 revisions
The rewrite rules in the .htaccess file are different than the default Wordpress file. We want to redirect all page URLs to our web app located at https://integreat.app, while resources in the wp-content/uploads and other directories should be accessible.
A good tool to test mod_rewrite rules is available at https://htaccess.madewithlove.be/. Additionally, for debugging purposes, change the log level in the /etc/apache2/apache2.conf to LogLevel warn rewrite:trace3.
This is a list of URLs that can be used to validate the rewrite rules in the .htaccess:
- http://integreat/ -> 301 to https://integreat.app/
- http://integreat/augsburg/de/wp-activate.php -> 200 OK
- http://integreat/wp-activate.php -> 200 OK
- http://integreat/wp-login.php -> 200 OK
- http://integreat/wp-admin/ -> 200 OK
- http://integreat/augsburg/wp-admin/ -> 200 OK
- http://integreat/wp-includes/js/tinymce/wp-tinymce.php?c=1&ver=4800-20180716-tadv-4.7.13 -> 200 OK
- http://integreat/augsburg/wp-includes/js/tinymce/wp-tinymce.php?c=1&ver=4800-20180716-tadv-4.7.13 -> 200 OK
- http://integreat/augsburg/wp-includes/js/jquery/ui/button.min.js?ver=1.11.4
- http://integreat/wp-json/extensions/v3/sites -> 200 OK
- http://integreat/augsburg/de/ -> 301 to https://integreat.app/augsburg/de/
- http://integreat/wp-content/uploads/sites/2/2015/10/network49-150x150.png -> 200 OK
- http://integreat/wp-content/uploads/sites/2/2015/10/foo.png -> 404 Not Found
- http://integreat/wp-foo/bar.php -> 404 Not Found
- http://integreat/wp-foo.php -> 404 Not Found
- http://integreat/augsburg/de/foo/bar -> 301 to https://integreat.app/augsburg/de/foo/bar/
- http://integreat/augsburg/de/wp-json/extensions/v0/modified_content/pages?since=2015-01-25T09%3A27%3A49%2B0000 -> 200 OK