function validateit(theForm)
{
	if (!(/^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,4})+$/.test(theForm.email.value)))
	{
		alert("Invalid Email ID. Kindly enter the correct ID.");
		theForm.email.focus();
		return (false);
	}
}

function checkData1()
{
	if (document.form2.ss.value.length < 3){
	    alert("Enter at least three characters for search."); 
	    document.form2.ss.focus();
	    return false;
	}
	else{
		return true;
	}

}

function getblank(this1)  {
	if (this1.value = "Your e-mail here") {
		this1.value = "";
	}
    return true;	
}


function check_advanced_search(kw)  {
  error = 0;
  if (kw.length < 3) {
    error_message = "Please enter atleast 3 characters for search";
    error = 1;
  }

  if (error == 1) {
    alert(error_message);
    return false;
  } else {
    return true;
  }
} 





function openchild_nl(thisurl) 
{
	browserName = navigator.appName;
	browserVer = parseInt(navigator.appVersion);
	condition = !(( (browserName.indexOf("Explorer") >=0 ) && (browserVer < 4) ) ||  ((browserName.indexOf("Netscape") >=0 ) && (browserVer < 2) ) ) ;
	if (condition == true  )
		CanAnimate = true;
	else
		CanAnimate = false;

	var email_val = document.theForm.email.value;
	var from_site_val = document.theForm.from_site.value;
	var is_window_val = document.theForm.is_window.value;


	var thisurl_string = thisurl + "?email=" + email_val + "&from_site=" + from_site_val + "&is_window=" + is_window_val;

	if ( CanAnimate ) {
			msgWindow=window.open( '' ,'subwindow','toolbar=no,location=no,directories=no,status=yes,scrollbars=yes,menubar=no,resizable=yes,width=550,height=220');
			msgWindow.focus();
			msgWindow.location.href = thisurl_string;
	}
	else {
			msgWindow=window.open( thisurl_string,'subwindow','toolbar=no,location=no,directories=no,status=yes,scrollbars=yes,menubar=no,resizable=yes,width=550,height=220');
	}
}

function addBookmark(title,url) {

	if (window.sidebar) {
		window.sidebar.addPanel("Indian Leather portal", url,"");
		//return false;
	}
	else if( document.all ) {
		window.external.AddFavorite( url, "Indian Leather portal");
		//return false;
	}
	else if(navigator.appName == 'Netscape') {
		alert('Press (CTRL-D) to bookmark this page.');
		//return false;
	}
	return false;
}

browserName = navigator.appName;
browserVer = parseInt(navigator.appVersion);
condition = !(( (browserName.indexOf("Explorer") >=0 ) && (browserVer < 4) ) ||  ((browserName.indexOf("Netscape") >=0 ) && (browserVer < 2) ) ) ;
if (condition == true  )
    CanAnimate = true;
else
    CanAnimate = false;

function openchild(thisurl){
if ( CanAnimate ){
        msgWindow=window.open( '' ,'subwindow','toolbar=no,location=no,directories=no,status=yes,scrollbars=yes,menubar=no,resizable=yes,width=635,height=230,left=0,top=0');
        msgWindow.focus();
        msgWindow.location.href = thisurl;
}
else {
        msgWindow=window.open( thisurl,'subwindow','toolbar=no,location=no,directories=no,status=yes,scrollbars=yes,menubar=no,resizable=yes,width=635,height=360,left=0,top=0');
}
}

function openchildts(thisurl) 
{
	if ( CanAnimate ){
		msgWindow=window.open( '' ,'subwindow','toolbar=no,location=no,directories=no,status=yes,scrollbars=yes,menubar=no,resizable=yes,width=635,height=230,left=0,top=0');
		msgWindow.focus();
		msgWindow.location.href = thisurl;
	}
	else {
		msgWindow=window.open( thisurl,'subwindow','toolbar=no,location=no,directories=no,status=yes,scrollbars=yes,menubar=no,resizable=yes,width=635,height=360,left=0,top=0');
	}
}



document.write('<DIV CLASS="src p3 m2 off" id="sourcediv" style="position:absolute; width:298px; right:5px;" ONCLICK="javascript:location.href=\'/business-enquiry.html\'"><P CLASS="q9 f4 p5 p6 q2 bo">Free Sourcing Help Desk</P><P CLASS="f7 bo rd p5 p6">Sourcing Products from India?</P><P CLASS="bo p5 f4 p6">Tell suppliers exactly what you need </P><p class="p5"> <A HREF="/business-enquiry.html" CLASS="f7 bo">Post your purchase / sourcing requirements</A></p><P CLASS="f5 bg dt q1 q4 m1">Receive quotes only from genuine and pre-verified suppliers</P></DIV>');









var myWidth = 0, myHeight = 0;
function source() 
{
if( typeof( window.innerWidth ) == 'number' ) {
myWidth = window.innerWidth;
myHeight = window.innerHeight;
} else if( document.documentElement && ( document.documentElement.clientWidth || document.documentElement.clientHeight ) ) {
    myWidth = document.documentElement.clientWidth;
    myHeight = document.documentElement.clientHeight;
  } else if( document.body && ( document.body.clientWidth || document.body.clientHeight ) ) {
   myWidth = document.body.clientWidth;
   myHeight = document.body.clientHeight;
  }
var h = window.pageYOffset ||
document.body.scrollTop ||
document.documentElement.scrollTop;
var browserName=navigator.appName; 
if(document.getElementById('rightnav'))
	{
var intElemScrollHeight = document.getElementById('rightnav').scrollHeight;

var abc = document.getElementsByTagName('body')[0].scrollHeight;
var abc1 = abc-460;
var na = intElemScrollHeight+600;



var newh = intElemScrollHeight+160;
var s = intElemScrollHeight+160+254;
var newhn = intElemScrollHeight+160+h;
if (document.getElementById('sourcediv').className=="src p3 m2 off")
{
document.getElementById('sourcediv').style.marginTop = newh+"px";
document.getElementById('sourcediv').className="src p3 m2 on";
}

if (document.getElementById('sourcediv'))
	{
if (newh < h || abc1 > h)
{
document.getElementById('sourcediv').style.marginTop = h+"px";
if (abc1 < h)
{
document.getElementById('sourcediv').style.marginTop = abc1+"px";
}
if (newh > h)
{
document.getElementById('sourcediv').style.marginTop = newh+"px";
}
if (abc < na)
{
	
	document.getElementById('sourcediv').className="src p3 m2 off";
	
	}


}}}}



function addEvent( obj, type, fn ){ 
   if (obj.addEventListener){ 
	  obj.addEventListener( type, fn, false );
   }
   else if (obj.attachEvent){ 
	  obj["e"+type+fn] = fn; 
	  obj[type+fn] = function(){ obj["e"+type+fn]( window.event ); } 
	  obj.attachEvent( "on"+type, obj[type+fn] ); 
   } 

}
addEvent(window, 'scroll', source);
addEvent(window, 'resize', source);





