2011-06-10 21:55:32 +00:00
|
|
|
<?php
|
2011-07-03 16:27:27 +00:00
|
|
|
$country = $_GET['langId'];
|
|
|
|
|
|
|
|
if (preg_match('/^[A-Z0-9_]+\z/i', $country)) {
|
|
|
|
define('DS', DIRECTORY_SEPARATOR);
|
|
|
|
$languageDir = realpath(dirname(__FILE__) . '/../application/language');
|
|
|
|
$image = $languageDir . DS . $country . DS . 'flag.gif';
|
|
|
|
|
|
|
|
if (file_exists($image)) {
|
|
|
|
header('Content-Type: image/gif');
|
|
|
|
readfile(realpath($image));
|
|
|
|
}
|
|
|
|
}
|