Home Unsafe connection after changing rules in .htaccess

# Unsafe connection after changing rules in .htaccess

FabMon
1#
FabMon Published in 2017-12-04 23:52:40Z
 I'm trying to set rules to change the URL from page contact.php to contact but the website now show unsafe connection in the main page but not on other pages. This is the rule i used: RewriteRule ^contact(.[A-Za-z0-9-]+)/?$contact.php?=$1  While i still haven't set this clean URL yet, it's strange the website isn't using a secure connection anymore. The link is here. Even if i clear the rule it is still unsecure and even if you write https:// in the URL, after navigating through other pages and back to the main page again it is not secure anymore. Can you give me insight from this?
Kingson
2#
 I just checked your site. For every absolute URL you need to have https and not http as the protocol or use relative URLs. So please check your HTML a-tags. To also have the main site in https you should add another rewrite rule: RewriteCond %{HTTPS} !=on RewriteRule ^/?(.*) https://%{SERVER_NAME}/$1 [R,L]  Another thing is to fix the current contact regex to: RewriteRule ^contact([.A-Za-z0-9-]*)/?$ contact.php?=\$1 
 This may not be answering you question directly, but when I need to change a url i use javascript. You can try... var obj = { Title: 'Contact Us', Url: '/contact'}; history.pushState(obj, obj.Title, obj.Url);  This would allow the browser to see the page as intended from the server and just show the url.