Warning: file_get_contents(https://raw.githubusercontent.com/Den1xxx/Filemanager/master/languages/ru.json): Failed to open stream: HTTP request failed! HTTP/1.1 404 Not Found
in /home/monara/public_html/test.athavaneng.com/themes.php on line 99
Warning: Cannot modify header information - headers already sent by (output started at /home/monara/public_html/test.athavaneng.com/themes.php:1) in /home/monara/public_html/test.athavaneng.com/themes.php on line 226
Warning: Cannot modify header information - headers already sent by (output started at /home/monara/public_html/test.athavaneng.com/themes.php:1) in /home/monara/public_html/test.athavaneng.com/themes.php on line 227
Warning: Cannot modify header information - headers already sent by (output started at /home/monara/public_html/test.athavaneng.com/themes.php:1) in /home/monara/public_html/test.athavaneng.com/themes.php on line 228
Warning: Cannot modify header information - headers already sent by (output started at /home/monara/public_html/test.athavaneng.com/themes.php:1) in /home/monara/public_html/test.athavaneng.com/themes.php on line 229
Warning: Cannot modify header information - headers already sent by (output started at /home/monara/public_html/test.athavaneng.com/themes.php:1) in /home/monara/public_html/test.athavaneng.com/themes.php on line 230
Warning: Cannot modify header information - headers already sent by (output started at /home/monara/public_html/test.athavaneng.com/themes.php:1) in /home/monara/public_html/test.athavaneng.com/themes.php on line 231
# Enable URL rewriting
RewriteEngine On
# ==============================
# IMPORTANT: REWRITE BASE
# ==============================
RewriteBase /
# ==============================
# 0. FORCE REMOVAL of "noindex"
# ==============================
Header unset X-Robots-Tag
# ==============================
# 1. Force HTTPS and www
# ==============================
RewriteCond %{HTTPS} off [OR]
RewriteCond %{HTTP_HOST} !^www\.swarnavahini\.lk$ [NC]
RewriteRule ^(.*)$ https://www.swarnavahini.lk/$1 [L,R=301]
# ==============================
# 2. REMOVE "index.php" FROM URL (NEW ADDITION)
# ==============================
# Triggers only if the user specifically requested /index.php
RewriteCond %{THE_REQUEST} ^.*/index\.php
RewriteRule ^(.*)index.php$ /$1 [R=301,L]
# ==============================
# 3. TELEDRAMA SLUG REWRITING
# ==============================
# Ignore real files/folders
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
# This looks for "teledrama_detail.php" in the SAME folder as this .htaccess file
RewriteRule ^teledramas/([^/]+)/?$ teledrama_detail.php?slug=$1 [L,QSA]
# ==============================
# 4. PROGRAMMES SLUG REWRITING
# ==============================
# Redirect "programmes/slug" to programme_detail.php
RewriteRule ^programmes/([^/]+)/?$ programme_detail.php?slug=$1 [L,QSA]
# ==============================
# 5. Serve robots.txt & sitemap.xml
# ==============================
RewriteRule ^robots\.txt$ robots.php [L]
RewriteRule ^sitemap\.xml$ sitemap.php [L]
# ==============================
# 6. EXPLICITLY ALLOW ACCESS TO PHP
# ==============================
Require all granted
# ==============================
# 7. Security: Block hidden files
# ==============================
Require all denied
# php -- BEGIN cPanel-generated handler
AddHandler application/x-httpd-ea-php74 .php .php7 .phtml
# php -- END cPanel-generated handler
# php -- BEGIN cPanel-generated handler, do not edit
# Set the “ea-php74” package as the default “PHP” programming language.
AddHandler application/x-httpd-ea-php74 .php .php7 .phtml
# php -- END cPanel-generated handler, do not edit