diff --git a/src/Jirafeau/a.php b/src/Jirafeau/a.php index 26f4c72..3ddbfeb 100644 --- a/src/Jirafeau/a.php +++ b/src/Jirafeau/a.php @@ -156,6 +156,19 @@ if (isset ($_REQUEST [A_PERIOD]) && !empty ($_REQUEST [A_PERIOD])) { exit; } +// ======================================== +if (isset ($_REQUEST [A_LANG]) && !empty ($_REQUEST [A_LANG])) { + if (!preg_match ("/^([a-z0-9\+_\-]+)(\.[a-z0-9\+_\-]+)*@([a-z0-9\-]+\.)+[a-z]{2,6}$/i", $_REQUEST [A_LANG])) + $content = DEFAULT_LANG.NL; + else + $content = getSenderLang ($_REQUEST [A_LANG]).NL; + header ('HTTP/1.0 200 OK'); + header ('Content-Length: ' . strlen ($content)); + header ('Content-Type: text/plain'); + echo $content; + exit; +} + // ======================================== $doUpdate = false; if (isset ($_REQUEST [A_UPDATE]) && !empty ($_REQUEST [A_UPDATE])) { @@ -1074,6 +1087,7 @@ div.frame {border: 1px; border-style: solid; padding: 1em; margin: 1em;} $defaultChecked = []; $defaultChecked [isSenderTrack ($sender) ? "on" : "off"] = ' checked="checked"'; $defaultChecked [getSenderPeriod ($sender)] = ' selected="selected"'; +$defaultChecked [getSenderLang ($sender)] = ' selected="selected"'; echo '