diff --git a/includes/account.php b/includes/account.php index e139aa1..8c721e0 100644 --- a/includes/account.php +++ b/includes/account.php @@ -13,7 +13,7 @@ PARTICULAR PURPOSE. See the License for more details. */ - if($_SERVER[HTTP_HOST] == "secure.cacert.org") + if($_SERVER['HTTP_HOST'] == "secure.cacert.org") { $query = "select * from `emailcerts` where `serial`='$_SERVER[SSL_CLIENT_M_SERIAL]' and `revoked`=0 and UNIX_TIMESTAMP(`expire`) - UNIX_TIMESTAMP() > 0"; @@ -38,23 +38,31 @@ } $_SESSION['_config']['oldlocation'] = "account.php?".$_SESSION['_config']['oldlocation']; - header("location: https://$_SERVER[HTTP_HOST]/index.php?id=4"); + header("location: https://".$_SERVER['HTTP_HOST']."/index.php?id=4"); exit; } - } else if($_SERVER[HTTP_HOST] == "secure.cacert.org" && $_SESSION['profile']['id'] > 0) { + } else if($_SERVER['HTTP_HOST'] == "secure.cacert.org" && $_SESSION['profile']['id'] > 0) { $_SESSION['profile'] = mysql_fetch_assoc(mysql_query("select * from `users` where `id`='".$_SESSION['profile']['id']."'")); } - if($_SERVER[HTTP_HOST] == "secure.cacert.org" && ($_SESSION['profile']['id'] <= 0 || $_SESSION['profile']['loggedin'] == 0)) + if($_SERVER['HTTP_HOST'] == "secure.cacert.org" && ($_SESSION['profile']['id'] <= 0 || $_SESSION['profile']['loggedin'] == 0)) { header("location: https://www.cacert.org"); exit; } + if($_SERVER['HTTP_HOST'] == "secure.cacert.org" && $_SESSION['profile']['id'] > 0) + { + $query = "select sum(`points`) as `total` from `notary` where `to`='".$_SESSION['profile']['id']."' group by `to`"; + $res = mysql_query($query); + $row = mysql_fetch_assoc($res); + $_SESSION['profile']['points'] = $row['total']; + } + if($id == "logout") { $_SESSION['profile']['loggedin'] = 0; - header("location: https://$_SERVER[HTTP_HOST]/index.php"); + header("location: https://".$_SERVER['HTTP_HOST']."/index.php"); exit; } @@ -71,7 +79,7 @@ } $_SESSION['_config']['oldlocation'] = "account.php?".$_SESSION['_config']['oldlocation']; - header("location: https://$_SERVER[HTTP_HOST]/index.php?id=4"); + header("location: https://".$_SERVER['HTTP_HOST']."/index.php?id=4"); exit; } diff --git a/includes/general.php b/includes/general.php index fe6a694..b6b0bad 100644 --- a/includes/general.php +++ b/includes/general.php @@ -80,6 +80,7 @@ case 'da': $_SESSION['_config']['language'] = "da_DK"; break; case 'de': $_SESSION['_config']['language'] = "de_DE"; break; case 'es': $_SESSION['_config']['language'] = "es_ES"; break; + case 'fr': $_SESSION['_config']['language'] = "fr_FR"; break; case 'nl': $_SESSION['_config']['language'] = "nl_NL"; break; case 'pt': $_SESSION['_config']['language'] = "pt_PT"; break; case 'hu': $_SESSION['_config']['language'] = "hu_HU"; break; diff --git a/includes/general_stuff.php b/includes/general_stuff.php index 546a0be..251c09c 100644 --- a/includes/general_stuff.php +++ b/includes/general_stuff.php @@ -74,6 +74,7 @@ google_color_border = "FFFFFF"; Deutsch English Español + French Magyar Nederlands Português diff --git a/www/src-lic.php b/www/src-lic.php index eff5f25..1feb54a 100644 --- a/www/src-lic.php +++ b/www/src-lic.php @@ -1,7 +1,7 @@