eriks
October 25, 2021, 5:50am
5
Thanks!!
Found this in the forum and thanks to this link found the good scrips. TOP.
I have made a custom 404 page at
I have edited my .htaccess file to send broken links to this page using the code widget here:
It all works great - except, I don’t know how to set the HTML status code of my 404 page correctly. It currently returns a 200 status code.
I have tried both:
<?php**
** header("HTTP/1.0 404 Not Found"); **
**?>
AND
header($_SERVER[“SERVER_PROTOCOL”]." 404 Not Found");
In the 404 page header code, but still getting the 200 code returned. What am I doing wrong? …
Uploaded the following scripts to the server via .htaccess and everything works as it should.
#http: // to https://
RewriteCond %{HTTPS} off
RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI} [R=301,L]
#www to non-www
RewriteCond %{HTTP_HOST} ^www. [NC]
RewriteRule ^(.*)$ https://dilien.com/$1 [L,R=301]
RewriteEngine on
RewriteRule ^/?(.*).(html)$ /$1 [R=301,L]
RewriteEngine On
ErrorDocument 404 https://dilien.com/404/
And everything is working fine.
Hope this is also the right way with regard to Google ranking.
Have another problem see:
When the form is used, the e-mail does not arrive. You will receive a notification that the message has been sent successfully. Inquired with the hosting company and this is their answer:
I’ve looked at the source code of the input form, and the reason it doesn’t work is because it uses PHP’s mail function. It is easier to use an SMTP connector from your Office365 mail server. Moreover, the emails will never be regarded as spam because the Office365 mail server is the official mail server of di…
1 Like