
<!-- start contor vizitatori -->
<div id="contor">
	<!-- BEGIN: Powered by Supercounters.com -->
		<center>
			<script type="text/javascript" src="//widget.supercounters.com/ssl/online_i.js"></script><script type="text/javascript">sc_online_i(1460183,"ffffff","4b47b8");</script><br><noscript><a href="http://www.supercounters.com/">Free Online Counter</a></noscript>
		</center>
	<!-- END: Powered by Supercounters.com -->
</div>
<!-- end contor vizitatori 
//========================= -->
<?php
//start script trimite formular pe email
if($_POST['trimite_formular']){

$to = $_SESSION['email'];


if(($_POST["name"]!="")&&($_POST["email"]!="")&&($_POST["phone"]!="")&&($_POST["oras"]!="")&&($_POST["cod_securitate"]!="") and ($_POST["cod_securitate"] == "8")){
	
	$subject = "Solicitare de la site ".$_SERVER["SERVER_NAME"]."";
	$headers = "MIME-Version: 1.0"."\r\n";
	$headers .= "Content-type: text/html; charset=iso-8859-1"."\r\n";
	$headers .= "From: ".$_POST['email']."<".$_POST['email'].">"."\r\n";

	$content = '
		<TABLE width="800px" align="center" border="1" bgcolor="#ffffff" cellspacing="0" cellpadding="8">
			
				<TR><TD width="200px" align="left">Nume si prenume :</TD><TD>'.$_POST['name'].'</TD></TR>
				<TR><TD align="left">Adresa de email : </TD><TD>'.$_POST['email'].'</TD></TR>
				<TR><TD align="left">Nr telefon : </TD><TD>'.$_POST['phone'].'</TD></TR>
				<TR><TD align="left">Oras : </TD><TD>'.$_POST['oras'].'</TD></TR>
				<tr><td align="left">Detalii lucrare :</td><td>'.$_POST['detalii'].'</td></tr> 
			
		</TABLE>';
	
	mail($to , $subject, $content, $headers );
	
	echo "<script>alert('Solicitare trimisa cu succes . Va vom raspunde in cel mai scurt timp. Va multumim !')</script>";
}
else{
	echo "<script>alert('Solicitare esuata ! Mesajul nu este complet ! Va rugam verificati. ')</script>";
}
echo "<script>location.replace('index.php')</script>";
	}
//end script trimite formular pe email
?>
