function linksus(nume)
{
    if(nume!='')
	{
	 //alert(nume);
     document.getElementById(nume).style.display = 'block';
	 document.getElementById(nume).style.background =  "url( http://www.inventmedia.ro/images/bto_"+nume+".jpg ) no-repeat";
	 document.getElementById(nume).height="270";
     document.getElementById(nume).width="133";

	  return true;
    }
}

function linkstanga(nume)
{
    if(nume!='')
	{
	 //alert(nume);
     document.getElementById(nume).style.color="#E7692E";
	 document.getElementById(nume).style.marginTop="5px";
     document.getElementById(nume).style.marginLeft="15px";
	 document.getElementById(nume).style.fontFamily="Verdana";
	 document.getElementById(nume).style.fontSize="12px";
	  return true;
    }
}

function schimbimg(nume,numelink)
{
		//document.getElementById('picture').src.innerHTML=nume;
		document['picture'].src=nume;
		document.getElementById('myAnchor').href=numelink;
		return true;
}

function paginacontact()
{
	var id_societate=document.getElementById('id_societate').value;
	if(id_societate=='')
	{
		document.getElementById('error_contact').style.display = '';
		document.getElementById('error_contact').innerHTML = 'Numele si prenumele';
		return false;
	}
	
	var id_conpania=document.getElementById('id_conpania').value;
	if(id_conpania=='')
	{
		document.getElementById('error_contact').style.display = '';
		document.getElementById('error_contact').innerHTML = 'Compania';
		return false;
	}
	
	var id_tel=document.getElementById('id_tel').value;
	if(id_tel=='')
	{
		document.getElementById('error_contact').style.display = '';
		document.getElementById('error_contact').innerHTML = 'Telefon';
		return false;
	}
	
	var reg=/^[a-z0-9._-]+@[a-z0-9.-]{2,}[.][a-z]{2,3}$/
    var email=document.getElementById('idemail').value;
    if(reg.exec(email)=='')
	{
		document.getElementById('error_contact').style.display = '';
		document.getElementById('error_contact').innerHTML = 'E-mail';
		return false;
	}
	
	var id_mesaj=document.getElementById('id_mesaj').value;
	if(id_mesaj=='')
	{
		document.getElementById('error_contact').style.display = '';
		document.getElementById('error_contact').innerHTML = 'Mesajul dumneavoastra';
		return false;
	}
	
	 var user_text = document.getElementById('user_text').value;
     var sesiune_cod = document.getElementById('sesiune_cod').value;
     if(user_text!=sesiune_cod)
      {
       document.getElementById('error_contact').style.display='';
       document.getElementById('error_contact').innerHTML="Codul de verificare nu este corect !";
      return false;
     }
	
	return true;
}

function verif_newsl()
{
  var reg=/^[a-z0-9._-]+@[a-z0-9.-]{2,}[.][a-z]{2,3}$/
    var email=document.getElementById('id_email').value;
    if(reg.exec(email)==null)
	{
		document.getElementById('error_newsl').style.display = '';
		document.getElementById('error_newsl').innerHTML = 'E-mail';
		return false;
	}
 return true;
}

function reset()
{
 document.getElementById('id_email').value='';
 return true;
}
