diff --git a/README.md b/README.md index 3d66b8c..28323d9 100644 --- a/README.md +++ b/README.md @@ -57,8 +57,16 @@ RewriteEngine On # Redirect year-based URLs to the archive site RewriteCond %{REQUEST_URI} ^/([0-9]{4})(/.*)?$ + +# Check if corresponding archive folder exists +RewriteCond ../archive/%1 -d + RewriteRule ^([0-9]{4})(/.*)?$ https://archive.harucon.org.il/%1%2 [R=301,L] +# Otherwise, redirect to the root site +RewriteCond %{REQUEST_URI} ^/(\d{4})(/.*)?$ [NC] +RewriteRule ^(\d{4})(/.*)?$ https://harucon.org.il/ [R=302,L] + # End of the .htaccess for harucon.org.il ``` @@ -87,8 +95,16 @@ RewriteEngine On # Redirect year-based URLs to the archive site RewriteCond %{REQUEST_URI} ^/([0-9]{4})(/.*)?$ + +# Check if corresponding archive folder exists +RewriteCond /home/hikaruj/public_html/convention_sites/animatsuri/archive/%1 -d + RewriteRule ^([0-9]{4})(/.*)?$ https://archive.animatsuri.org.il/%1%2 [R=301,L] +# Otherwise, redirect to the root site +RewriteCond %{REQUEST_URI} ^/(\d{4})(/.*)?$ [NC] +RewriteRule ^(\d{4})(/.*)?$ https://animatsuri.org.il/ [R=302,L] + # End of the .htaccess for animatsuri.org.il ```