0) {
foreach($IPListe as $Zeile) {
$GesplitteteZeile = explode("|", $Zeile);
if(($GesplitteteZeile[0]+$Zeitsperre) > time()){
$NeueIPListe[] = trim($Zeile)."\n";
}
}
if(count($NeueIPListe) > 0){
foreach($NeueIPListe as $Zeile){
$GesplitteteZeile = explode("|", $Zeile);
if(trim($GesplitteteZeile[1]) == $_SERVER['REMOTE_ADDR']){
$Gefunden = TRUE;
}
}
}
}
$FilePointerIP = fopen($DateinameIP, "w");
if(count($IPListe) > 0 && count($NeueIPListe) > 0){
foreach($NeueIPListe as $Zeile) {
fwrite($FilePointerIP, trim($Zeile)."\n");
}
}
if(!$Gefunden) {
// Länderkennung auf "de", "se" oder "en" kürzen
if ($_SERVER["HTTP_ACCEPT_LANGUAGE"] != "") {
$Schluesselarray = explode(",",$_SERVER["HTTP_ACCEPT_LANGUAGE"]);
$Schluesselarray2 = explode("-",$Schluesselarray[0]);
$Schluessel = $Schluesselarray2[0];
}
if($Schluessel) fwrite($FilePointerIP, time()."|".$_SERVER['REMOTE_ADDR']."|$Schluessel\n");
}
fclose($FilePointerIP);
// + + + Länderkennung dazu + + +
$FilePointerLang = fopen($DateinameLang, "a");
if(!$Gefunden) {
// Länderkennung auf "de", "se" oder "en" kürzen
if ($_SERVER["HTTP_ACCEPT_LANGUAGE"] != "") {
$Schluesselarray = explode(",",$_SERVER["HTTP_ACCEPT_LANGUAGE"]);
$Schluesselarray2 = explode("-",$Schluesselarray[0]);
$Schluessel = $Schluesselarray2[0];
}
fwrite($FilePointerLang, "$Schluessel|");
}
fclose($FilePointerLang);
// + + + Länderkennung dazu + + +
$FilePointerCount = fopen($DateinameCount, "r+");
$Counter = fread($FilePointerCount, filesize($DateinameCount));
if(!$Gefunden){
$Counter++;
rewind($FilePointerCount);
fwrite($FilePointerCount, $Counter);
}
fclose($FilePointerCount);
if($_GET['action'] == "statistik") { ?>
BSIS-Statistik
Besucher
0) {
// Counter ausgeben
echo "
$Counter
Besucher insgesamt, seit 12.11.2007 ($Tage Tage)
$Anzahl24Stunden
Besucher in den letzten 24 Stunden
$BesucherProTag
Besucher pro Tag im Durchschnitt";
}
// Länder-Statistik
$FilePointerLangAusgabe = fopen($DateinameLang, "r");
$Inhalt = fread($FilePointerLangAusgabe, filesize($DateinameLang));
fclose($FilePointerLangAusgabe);
$array = explode("|",trim($Inhalt));
sort($array);
$AnzahlUnterschiedlicheSprachen = array_count_values($array);
$Insgesamt = count($array);
echo "
Ländererkennung
";
foreach($AnzahlUnterschiedlicheSprachen as $Schluessel=>$Wert){
if ($Schluessel == "af"){
$Land = Afrikaans;
}
elseif ($Schluessel == "sq"){
$Land = Albanien;
}
elseif ($Schluessel == "ar-sa"){
$Land = "Saudi Arabien"; // Arabic(Saudi Arabia)
}
elseif ($Schluessel == "ar-iq"){
$Land = Irak;
}
elseif ($Schluessel == "ar-eg"){
$Land = Ägypten;
}
elseif ($Schluessel == "ar-ly"){
$Land = Lybien;
}
elseif ($Schluessel == "ar-dz"){
$Land = Algerien;
}
elseif ($Schluessel == "ar-ma"){
$Land = Marokko;
}
elseif ($Schluessel == "ar-tn"){
$Land = Tunesien; // Arabic(Tunisia)
}
elseif ($Schluessel == "ar-om"){
$Land = Oman; // Arabic(Oman)
}
elseif ($Schluessel == "ar-ye"){
$Land = Yemen; // Arabic(Yemen)
}
elseif ($Schluessel == "ar-sy"){
$Land = Syrien; // Arabic(Syria)
}
elseif ($Schluessel == "ar-jo"){
$Land = Jordanien; // Arabic(Jordan)
}
elseif ($Schluessel == "ar-lb"){
$Land = Libanon; // Arabic(Lebanon)
}
elseif ($Schluessel == "ar-kw"){
$Land = Kuwait; // Arabic(Kuwait)
}
elseif ($Schluessel == "ar-ae"){
$Land = U.A.E; // Arabic(U.A.E.)
}
elseif ($Schluessel == "ar-bh"){
$Land = 15361; // Arabic(Bahrain)
}
elseif ($Schluessel == "ar-qa"){
$Land = 16385; // Arabic(Qatar)
}
elseif ($Schluessel == "eu"){
$Land = 1069; // Basque
}
elseif ($Schluessel == "bg"){
$Land = Bulgarien; // Bulgarian
}
elseif ($Schluessel == "be"){
$Land = Weißrussland; // Belarusian
}
elseif ($Schluessel == "ca"){
$Land = 1027; // Catalan
}
elseif ($Schluessel == "zh-tw"){
$Land = 1028; // Chinese(Taiwan)
}
elseif ($Schluessel == "zh-cn"){
$Land = 2052; // Chinese(PRC)
}
elseif ($Schluessel == "zh-hk"){
$Land = 3076; // Chinese(Hong Kong)
}
elseif ($Schluessel == "zh-sg"){
$Land = 4100; // Chinese(Singapore)
}
elseif ($Schluessel == "zh"){
$Land = China; // Chinese(Singapore)
}
elseif ($Schluessel == "hr"){
$Land = Kroatien; // Croatian
}
elseif ($Schluessel == "cs"){
$Land = "Tschechische Republik"; // Czech
}
elseif ($Schluessel == "da"){
$Land = Dänemark; // Danish
}
elseif ($Schluessel == "nl"){
$Land = Niederlande; // Dutch(Standard)
}
elseif ($Schluessel == "nl-be"){
$Land = Belgien; // Dutch(Belgian)
}
elseif ($Schluessel == "en"){
$Land = "Englischer Sprachraum"; // English 9
}
elseif ($Schluessel == "en-us"){
$Land = USA; // English(United States)
}
elseif ($Schluessel == "en-gb"){
$Land = Großbritanien; // English(British)
}
elseif ($Schluessel == "en-au"){
$Land = Australien; // English(Australian)
}
elseif ($Schluessel == "en-ca"){
$Land = Kanada; // English(Canadian)
}
elseif ($Schluessel == "en-nz"){
$Land = Neuseeland; // English(New Zealand)
}
elseif ($Schluessel == "en-ie"){
$Land = Irland; // English(Ireland)
}
elseif ($Schluessel == "en-za"){
$Land = Südafrika; // English(South Africa)
}
elseif ($Schluessel == "en-jm"){
$Land = 8201; // English(Jamaica)
}
elseif ($Schluessel == "en-ca"){
$Land = 9225; // English(Caribbean)
}
elseif ($Schluessel == "en-bz"){
$Land = 10249; // English(Belize)
}
elseif ($Schluessel == "en-tt"){
$Land = 11273; // English(Trinidad)
}
elseif ($Schluessel == "et"){
$Land = Estland; // Estonian
}
elseif ($Schluessel == "fo"){
$Land = 1080; // Faeroese
}
elseif ($Schluessel == "fa"){
$Land = 1065; // Farsi
}
elseif ($Schluessel == "fi"){
$Land = Finnland; // Finnish
}
elseif ($Schluessel == "fr"){
$Land = Frankreich; // French(Standard)
}
elseif ($Schluessel == "fr-be"){
$Land = Belgien; // French(Belgian)
}
elseif ($Schluessel == "fr-ca"){
$Land = Kanada; // French(Canadian)
}
elseif ($Schluessel == "fr-ch"){
$Land = Schweiz; // French(Swiss)
}
elseif ($Schluessel == "fr-lu"){
$Land = Luxemburg; // French(Luxembourg)
}
elseif ($Schluessel == "mk"){
$Land = 1071; // Macedonian (FYROM)
}
elseif ($Schluessel == "gd"){
$Land = 1084; // Gaelic(Scots)
}
elseif ($Schluessel == "de"){
$Land = Deutschland; // German(Standard) 1031
}
elseif ($Schluessel == "de-de"){
$Land = Deutschland; // German(Standard)
}
elseif ($Schluessel == "de-ch"){
$Land = Schweiz; // German(Swiss)
}
elseif ($Schluessel == "de-at"){
$Land = Österreich; // German(Austrian)
}
elseif ($Schluessel == "de-lu"){
$Land = Luxemburg; // German(Luxembourg)
}
elseif ($Schluessel == "de-li"){
$Land = Lichtenstein; // German(Liechtenstein)
}
elseif ($Schluessel == "el"){
$Land = Griechenland; // Greek
}
elseif ($Schluessel == "he"){
$Land = 1037; // Hebrew
}
elseif ($Schluessel == "hi"){
$Land = 1081; // Hindi
}
elseif ($Schluessel == "hu"){
$Land = 1038; // Hungarian
}
elseif ($Schluessel == "in"){
$Land = Island; // Icelandic
}
elseif ($Schluessel == "in"){
$Land = 1057; // Indonesian
}
elseif ($Schluessel == "it"){
$Land = Italien; // Italian(Standard)
}
elseif ($Schluessel == "it-ch"){
$Land = Schweiz; // Italian(Swiss)
}
elseif ($Schluessel == "ja"){
$Land = Japan; // Japanese
}
elseif ($Schluessel == "ko"){
$Land = Korea; // Korean
}
elseif ($Schluessel == "ko"){
$Land = 2066; // Korean(Johab)
}
elseif ($Schluessel == "lv"){
$Land = Lettland; // Latvian
}
elseif ($Schluessel == "lt"){
$Land = Litauen; // Lithuanian
}
elseif ($Schluessel == "ms"){
$Land = 1086; // Malaysian
}
elseif ($Schluessel == "mt"){
$Land = Malta; // Maltese
}
elseif ($Schluessel == "no"){
$Land = Norwegen; // Norwegian(Bokmal)
}
elseif ($Schluessel == "pl"){
$Land = Polen; // Polish 1045
}
elseif ($Schluessel == "pt-br"){
$Land = Brasilien; // Portuguese(Brazil)
}
elseif ($Schluessel == "pt"){
$Land = Portugal; // Portuguese(Portugal)
}
elseif ($Schluessel == "rm"){
$Land = 1047; // Rhaeto-Romanic
}
elseif ($Schluessel == "ro"){
$Land = Rumainien; // Romanian
}
elseif ($Schluessel == "ro-mo"){
$Land = 2072; // Romanian(Moldavia)
}
elseif ($Schluessel == "ru"){
$Land = Russland; // Russian 1049
}
elseif ($Schluessel == "ru-mo"){
$Land = 2073; // Russian(Moldavia)
}
elseif ($Schluessel == "sz"){
$Land = 1083; // Sami(Lappish)
}
elseif ($Schluessel == "sr"){
$Land = 3098; // Serbian(Cyrillic)
}
elseif ($Schluessel == "sr"){
$Land = 2074; // Serbian(Latin)
}
elseif ($Schluessel == "sk"){
$Land = 1051; // Slovak
}
elseif ($Schluessel == "sl"){
$Land = 1060; // Slovenian
}
elseif ($Schluessel == "sb"){
$Land = 1070; // Sorbian
}
elseif ($Schluessel == "es"){
$Land = Spanien; // Spanish(Spain - Traditional Sort)
}
elseif ($Schluessel == "es-mx"){
$Land = 2058; // Spanish(Mexican)
}
elseif ($Schluessel == "es-gt"){
$Land = 4106; // Spanish(Guatemala)
}
elseif ($Schluessel == "es-cr"){
$Land = 5130; // Spanish(Costa Rica)
}
elseif ($Schluessel == "es-pa"){
$Land = 6154; // Spanish(Panama)
}
elseif ($Schluessel == "es-do"){
$Land = 7178; // Spanish(Dominican Republic)
}
elseif ($Schluessel == "es-ve"){
$Land = 8202; // Spanish(Venezuela)
}
elseif ($Schluessel == "es-co"){
$Land = 9226; // Spanish(Colombia)
}
elseif ($Schluessel == "es-pe"){
$Land = 10250; // Spanish(Peru)
}
elseif ($Schluessel == "es-ar"){
$Land = 11274; // Spanish(Argentina)
}
elseif ($Schluessel == "es-ec"){
$Land = 12298; // Spanish(Ecuador)
}
elseif ($Schluessel == "es-c"){
$Land = 13322; // Spanish(Chile)
}
elseif ($Schluessel == "es-uy"){
$Land = 14346; // Spanish(Uruguay)
}
elseif ($Schluessel == "es-py"){
$Land = 15370; // Spanish(Paraguay)
}
elseif ($Schluessel == "es-bo"){
$Land = 16394; // Spanish(Bolivia)
}
elseif ($Schluessel == "es-sv"){
$Land = 17418; // Spanish(El Salvador)
}
elseif ($Schluessel == "es-hn"){
$Land = 18442; // Spanish(Honduras)
}
elseif ($Schluessel == "es-ni"){
$Land = 19466; // Spanish(Nicaragua)
}
elseif ($Schluessel == "es-pr"){
$Land = 20490; // Spanish(Puerto Rico)
}
elseif ($Schluessel == "sx"){
$Land = 1072; // Sutu
}
elseif ($Schluessel == "sv"){
$Land = Schweden; // Swedish 1053
}
elseif ($Schluessel == "sv-fi"){
$Land = 2077; // Swedish(Finland)
}
elseif ($Schluessel == "th"){
$Land = 1054; // Thai
}
elseif ($Schluessel == "ts"){
$Land = 1073; // Tsonga
}
elseif ($Schluessel == "tn"){
$Land = 1074; // Tswana
}
elseif ($Schluessel == "tr"){
$Land = Türkei; // Turkish
}
elseif ($Schluessel == "uk"){
$Land = Ukraine; // Ukrainian
}
elseif ($Schluessel == "ur"){
$Land = 1056; // Urdu
}
elseif ($Schluessel == "ve"){
$Land = 1075; // Venda
}
elseif ($Schluessel == "vi"){
$Land = 1066; // Vietnamese
}
elseif ($Schluessel == "xh"){
$Land = 1076; // Xhosa
}
elseif ($Schluessel == "ji"){
$Land = 1085; // Yiddish
}
elseif ($Schluessel == "zu"){
$Land = Zulu; // Zulu
}
else {
$Land = $Schluessel; // default
}
$Prozent = round($Wert / $Insgesamt * 100, 2);
$ProzentBreite = ceil($Wert / $Insgesamt * 100);
if(trim($Schluessel) != "") echo "| $Land [$Prozent%] |
|
";
}
echo "
"; ?>
Copyright © Baltic Sea Ice Service
E-Mail: marina.kirchhoff@bsh.de
Stand: