fixed .htaccess

This commit is contained in:
Ludwig Lehnert 2025-04-21 17:35:59 +00:00
parent 4ec40e4f70
commit a450316858
2 changed files with 4 additions and 2 deletions

View File

@ -1,9 +1,11 @@
RewriteEngine On RewriteEngine On
RewriteBase /
# ------------------------------------------- # -------------------------------------------
# Rewrite /blog/<ID> to /blog.php?id=<ID> # Rewrite /blog/<ID> to /blog.php?id=<ID>
# ------------------------------------------- # -------------------------------------------
RewriteRule ^blog/([^/]+)/?$ /blog.php?id=$1 [L] RewriteRule ^blog/([^/]+)$ /blog/$1/ [L]
RewriteRule ^blog/([^/]+)/$ blog.php?id=$1 [L]
# ------------------------------------------- # -------------------------------------------
# Rewrite /sitemap.xml to /blog.php?id=<ID> # Rewrite /sitemap.xml to /blog.php?id=<ID>

View File

@ -18,7 +18,7 @@ $rand_send_comment = mt_rand() % 5;
function is_external_url(string $url): bool function is_external_url(string $url): bool
{ {
return !str_starts_with($url, '#'); return str_starts_with($url, 'http');
} }
?><!DOCTYPE html> ?><!DOCTYPE html>