$unique_id=md5 (uniqid (rand())); session_id($unique_id); header("Expires: ".GMDate("D, d M Y H:i:s")." GMT"); require "../admin/function.php"; mysql_select_db("emails"); ?>
if (sizeof($HTTP_GET_VARS) == 0): ?> endif; if (sizeof($HTTP_GET_VARS) > 0): // nevyplnene povinne udaje if ($HTTP_GET_VARS['souhlas'] != 'ano' || $HTTP_GET_VARS['jmeno']=="" || $HTTP_GET_VARS['email']=="@" || $HTTP_GET_VARS['tel2']="") : echo("Nevyplnili jste všechny povinné údaje ve formuláři. Použijte tlačítko ZPěT ve Vašem prohlížeči a vyplňte, prosím, všechny chybějící údaje."); exit; endif; // odeslat data $text =""; $text = $text. "Byl vyplnen soutezni formular s nasledujicimi odpovedmi: \n\n"; $text = $text. "Odpoved prvni: ".$HTTP_GET_VARS['prvni']."\n"; //$text = $text. "Odpoved druha: ".$HTTP_GET_VARS['druha']."\n"; //$text = $text. "Odpoved treti: ".$HTTP_GET_VARS['treti']."\n"; $text = $text. "Odpoved Jmeno: ".$HTTP_GET_VARS['jmeno']."\n"; $text = $text. "Odpoved Email: ".$HTTP_GET_VARS['email']."\n"; $text = $text. "Odpoved Adresa: ".$HTTP_GET_VARS['adresa']."\n"; $text = $text. "Odpoved Tel.: ".$HTTP_GET_VARS['telefon']."\n"; $text = $text. "Odpoved souhlas: ".$HTTP_GET_VARS['souhlas']."\n"; mail("soutez@euroshow2000.cz","SOUTEZ",$text); // zpracovani zadaneho emailu $q1 = MySQL_QUERY("select * from addresses where address = '".$HTTP_GET_VARS['email']."'"); $pocet = MySQL_NUM_ROWS($q1); if ($pocet > 0) : // email uz existuje, jen se potvrdi souhlas $q2 = MySQL_QUERY("update addresses set approved_competition=1 where address = '".$HTTP_GET_VARS['email']."'"); endif; if ($pocet == 0) : // email jeste neexistuje, pridat a potvrdit soutez $q3 = MySQL_QUERY("insert into addresses(address,contacted,approved_competition) values('".$HTTP_GET_VARS['email']."',1,1)"); endif; echo("Vaše odpovědi byly uloženy. Děkujeme za Váš zájem.Team Euroshow2000,
http://www.euroshow2000.cz