function linksus(nume)
{
    if((nume!='')&&(nume!='sitemaps'))
	{
	 //alert(nume);
	 document.getElementById(nume).style.background="url(http://www.ddptrailer.ro/images/"+nume+"-ov.jpg)";
	 document.getElementById(nume).style.display='block';
	 document.getElementById(nume).style.color = "#fff";
	 document.getElementById(nume).style.height = "28px";
     return true;
    }
}


function schimbimg(nume)
{
		document.getElementById('picture').src=nume;
		//document['picture'].src=nume;
		//document.getElementById('myAnchor').href=numelink;
		document.getElementById('div_content2').style.display='';
		document.getElementById('div_content').style.display='none';
		document.getElementById('picture').style.display='';
		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('id_email').value;
    if(reg.exec(email)==null)
	{
		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;
}
