issue setting up HTTPS
Posted: Sat May 07, 2011 2:55 pm
There are some of my pages that I want to make secure (SSL) but I'm having issues with it.
I tried just setting the 'Use HTTPS for this page:' but when I checked this box, the page would then get a 'The page isn't redirecting properly' in Firefox and wouldn't load in IE.
I then set up a UDT and added it to the template and this works fine. The page redirects to HTTPS.
BUT, the links to the css/js etc... on the webpage are all still http. This causes issues then with IE and forms on the site pointing to http and not https.
I've attached the htaccess file so that you can see how this is set up.
CMS Version 1.9.2
Current PHP Version (phpversion): 5.2.9
Server Software (server_software): Apache/2.2.11 (Unix)
url_rewriting: mod_rewrite
page_extension: .htm
I tried just setting the 'Use HTTPS for this page:' but when I checked this box, the page would then get a 'The page isn't redirecting properly' in Firefox and wouldn't load in IE.
I then set up a UDT and added it to the template and this works fine. The page redirects to HTTPS.
Code: Select all
if ($_SERVER['HTTP_HOST']=='www.domainname.ie' && $_SERVER['SERVER_PORT']!=443)
{
$url = "https://". $_SERVER['SERVER_NAME'] . $_SERVER['REQUEST_URI'];
header("Location: $url");
}
I've attached the htaccess file so that you can see how this is set up.
CMS Version 1.9.2
Current PHP Version (phpversion): 5.2.9
Server Software (server_software): Apache/2.2.11 (Unix)
url_rewriting: mod_rewrite
page_extension: .htm