var bool=true;
function elections_links(){
cap=document.getElementById('similar_videos_link');
rand=(Math.random()*10000000).toString();
rand=rand.substr(0,6);
if(bool){
capurl=cap.src;
bool=false;
}
cap.src=capurl+"/?subheading2="+rand;


}


function ind_spng_srch(thisform)
{
var emailRegEx = /^[A-Z0-9._%+-]+@[A-Z0-9.-]+\.[A-Z]{2,4}$/i;
var email = document.getElementById('chrome7').value;
  var fields = '';
  var errorcount = 0;
  if(document.getElementById('desc_body').value == "")
  {
    errorcount++;
    if(errorcount > 1)
        fields = fields + " and Name";
    else
        fields = fields + "Name";
  }

  if(document.getElementById('chrome7').value == "" || email.search(emailRegEx)== -1)
  {
    errorcount++;
    if(errorcount > 1)
        fields = fields + " and Email";
    else
        fields = fields + "Email";
  }
  if(document.getElementById('feature_content').value != rand)
  {
    errorcount++;
    if(errorcount > 1)
        fields = fields + " and Security";
    else
        fields = fields + "Security";
  }
  
  if(document.getElementById('bot').value == "")
  {
    errorcount++;
    if(errorcount > 1)
        fields = fields + " and Message";
    else
        fields = fields + "Message";
  }

  if(errorcount > 0)
  {
    document.getElementById('t1_deal2').innerHTML = '<span class="feedservices">Invalid Fields: '+fields+'</span>';
    return false;
  }

  return true;
}

