Error - SSL received a record that exceeded the maximum...

Professional Joomla restaurant template comes with a custom animated modules and advanced typography elements.
GK User
Tue Sep 30, 2014 7:09 pm
Switch error from http to https...
anyone know why script that changes url to HTTPS do not work on this template for some of my modules...
find below the script that I placed in the header section of the template layout default.php?? It works fine on native joomla 3x when put in the index.php, but I cant get it to work in Gavern Resturant template..Any Ideas how this might be resolved??


<?php
// SSL received a record that exceeded the maximum permissible length
// check the URL for modules that need SSL
if ((strpos($_SERVER["REQUEST_URI"], "com_dtregister") > 0) || (strpos($_SERVER["REQUEST_URI"], "com_dtdonate") > 0 )|| $_REQUEST['option']=='com_dtdonate' || $_REQUEST['option']=='com_dtregister')
{
// only rewrite the URL once, if you are not in https: mode
if ($_SERVER['SERVER_PORT'] == 80)
{
if($_SERVER['REQUEST_METHOD']=='POST'){
}else{
header( 'Location: https://' . $_SERVER["HTTP_HOST"] . $_SERVER["REQUEST_URI"]);
}
}
}
// check to see if https: is not required
if ((strpos($_SERVER["REQUEST_URI"], "com_dtregister") === false) && (strpos($_SERVER["REQUEST_URI"], "com_dtdonate") === false) && $_REQUEST['option']!='com_dtdonate' && $_REQUEST['option']!='com_dtregister')
{
// only rewrite the URL once, if you are already in https: mode
if ($_SERVER['SERVER_PORT'] == 443)
{
if($_SERVER['REQUEST_METHOD']=='POST'){
}else{
header( 'Location: http://' . $_SERVER["HTTP_HOST"] . $_SERVER["REQUEST_URI"]);
}
}
}
?>
User avatar
Fresh Boarder

teitbite
Thu Oct 02, 2014 8:43 am
Hi

I'm not entirely sure, but probably adding

Code: Select all
exit;


after the header redirection may help. I think right now site is still being loaded even if new one is trying to load and not completed action gives this error.
User avatar
Moderator


cron