When I input www.example.com/qqqqqq (consider example.com is my domain) in url or any arbitrary url it should display 404 error but it is displaying 500 internal server error. This is my .htaccess file, please help me.
Options All -Indexes
RewriteEngine on
RewriteCond %{HTTP_HOST} ^example.com [NC]
RewriteRule ^(.*)$ http://www.example.com/$1 [L,R=301,NC]
RewriteRule ^product-([0-9a-zA-Z]+) p.php?en=$1 [NC,L]
RewriteRule ^category/([0-9a-zA-Z]+) as.php?en=$1 [NC,L]
RewriteCond %{REQUEST_FILENAME}.php -f
RewriteCond %{REQUEST_URI} !/$
RewriteRule ^(.*)$ $1\.php
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ $1.html [L]
#Error Pages
ErrorDocument 404 /404.php
#gzip compression
<ifModule mod_gzip.c>
mod_gzip_on Yes
mod_gzip_dechunk Yes
mod_gzip_item_include file .(html?|txt|css|js|php|pl)$
mod_gzip_item_include handler ^cgi-script$
mod_gzip_item_include mime ^text/.*
mod_gzip_item_include mime ^application/x-javascript.*
mod_gzip_item_exclude mime ^image/.*
mod_gzip_item_exclude rspheader ^Content-Encoding:.*gzip.*
</ifModule>
This is .htaccess file please help me 404.php