function changue(a,b,c)
{
document.frm_directory.submit_link.value = a;
document.frm_directory.membership_price.value = b;
document.frm_directory.membership_title.value = c;

if (b>0)
{
document.frm_directory.backlink.disabled=true;
} else 
{ 
document.frm_directory.backlink.disabled=false;
}
return;
}
function changetabs(tabname)
{
	var myobj,imgsrc1,imgsrc2,imgsrc3,imgsrc4,imgsrc5,imgsrc6,imgsrc7,myobj1,myobj2,myobj3,myobj4,myobj5,myobj6,myobj7,condition;
	
	if (tabname=='summary')
	{
		condition=' ';
		if(document.getElementById("tabproducts") != null)
		{
			myobj2 = document.getElementById("tabproducts");
			imgsrc2 = myobj2.src;
			
			if (condition.length ==1)
				{
					
					condition= 'imgsrc2.indexOf("_on.gif")> 0';
				} else {
					condition= '|| imgsrc2.indexOf("_on.gif")> 0';
					}
		}	
		
		if(document.getElementById("tabcomments") != null)
		{
			myobj3 = document.getElementById("tabcomments");
			imgsrc3 = myobj3.src;
			
			if (condition.length == 1)
				{
					condition=condition + 'imgsrc3.indexOf("_on.gif")> 0';
				}
				  else {
					  condition=condition + '|| imgsrc3.indexOf("_on.gif")> 0';
					  }
		}
		
		if(document.getElementById("tabphotos") != null)
		{
			myobj4 = document.getElementById("tabphotos");
			imgsrc4 = myobj4.src;
			if (condition.length == 1)
				{
					condition=condition + 'imgsrc4.indexOf("_on.gif")> 0';
				}
				  else {
					  condition=condition + '|| imgsrc4.indexOf("_on.gif")> 0';
					  }
		}
		
		if(document.getElementById("tabbooks") != null)
		{
			myobj5 = document.getElementById("tabbooks");
			imgsrc5 = myobj5.src;
			if (condition.length == 1)
				{
					condition=condition + 'imgsrc5.indexOf("_on.gif")> 0';
				}
				  else {
					  condition=condition + '|| imgsrc5.indexOf("_on.gif")> 0';
					  }
		}
		
		if(document.getElementById("tabpuppies") != null)
		{
			myobj6 = document.getElementById("tabpuppies");
			imgsrc6 = myobj6.src;
			if (condition.length == 1)
				{
					condition=condition + 'imgsrc6.indexOf("_on.gif")> 0';
				}
				  else {
					  condition=condition + '|| imgsrc6.indexOf("_on.gif")> 0';
					  }
		}
		
		if(document.getElementById("tabvideos") != null)
		{
			myobj7 = document.getElementById("tabvideos");
			imgsrc7 = myobj7.src;
			if (condition.length == 1)
				{
					
					condition=condition + 'imgsrc7.indexOf("_on.gif")> 0';
				}
				  else {
					  condition=condition + '|| imgsrc7.indexOf("_on.gif")> 0';
					  }
		}
		
		if (condition)  
		{
			
			if(document.getElementById("tabproducts") != null)
			{
				myobj2.src = "http://" + location.host + "/work/tabs/productsoff.gif";
				document.getElementById("lproducts").style.display = "none";
			}
			
			if(document.getElementById("tabcomments") != null)
			{
				myobj3.src = "http://" + location.host + "/work/tabs/commentsoff.gif";
				document.getElementById("comments").style.display = "none";
			}
			
			if(document.getElementById("tabphotos") != null)
			{
			myobj4.src = "http://" + location.host + "/work/tabs/photosoff.gif";
			document.getElementById("photos").style.display = "none";
			}
			
			if(document.getElementById("tabbooks") != null)
			{
			myobj5.src = "http://" + location.host + "/work/tabs/booksoff.gif";
			document.getElementById("books").style.display = "none";
			}
			
			if(document.getElementById("tabpuppies") != null)
			{
			myobj6.src = "http://" + location.host + "/work/tabs/puppiesoff.gif";
			document.getElementById("puppies").style.display = "none";
			}
			
			if(document.getElementById("tabvideos") != null)
			{
			myobj7.src = "http://" + location.host + "/work/tabs/videosoff.gif";
			document.getElementById("videos").style.display = "none";
			}
			
			myobj = document.getElementById("tabsummary");
			myobj.src = "http://" + location.host + "/work/tabs/summary_on.gif";
			document.getElementById("summary").style.display = "block";
		}	
	}
	
	if (tabname=='lproducts') 
	{
	
		condition=' ';
		
		if(document.getElementById("tabsummary") != null)
		{
			myobj1 = document.getElementById("tabsummary");
			imgsrc1 = myobj1.src;
			if (condition.length == 1)
				{
					
					condition=condition + 'imgsrc1.indexOf("_on.gif")> 0';
				}
				  else {
					  condition=condition + '|| imgsrc1.indexOf("_on.gif")> 0';
					  }
		}
		
		if(document.getElementById("tabcomments") != null)
		{
			
			myobj3 = document.getElementById("tabcomments");
			imgsrc3 = myobj3.src;
			
			if (condition.length == 1)
				{
					condition=condition + 'imgsrc3.indexOf("_on.gif")> 0';
				}
				  else {
					  condition=condition + '|| imgsrc3.indexOf("_on.gif")> 0';
					  }
		}
		
		if(document.getElementById("tabphotos") != null)
		{
			myobj4 = document.getElementById("tabphotos");
			imgsrc4 = myobj4.src;
			if (condition.length == 1)
				{
					condition=condition + 'imgsrc4.indexOf("_on.gif")> 0';
				}
				  else {
					  condition=condition + '|| imgsrc4.indexOf("_on.gif")> 0';
					  }
		}
		
		if(document.getElementById("tabbooks") != null)
		{
			myobj5 = document.getElementById("tabbooks");
			imgsrc5 = myobj5.src;
			if (condition.length == 1)
				{
					condition=condition + 'imgsrc5.indexOf("_on.gif")> 0';
				}
				  else {
					  condition=condition + '|| imgsrc5.indexOf("_on.gif")> 0';
					  }
		}
		
		if(document.getElementById("tabpuppies") != null)
		{
			myobj6 = document.getElementById("tabpuppies");
			imgsrc6 = myobj6.src;
			if (condition.length == 1)
				{
					condition=condition + 'imgsrc6.indexOf("_on.gif")> 0';
				}
				  else {
					  condition=condition + '|| imgsrc6.indexOf("_on.gif")> 0';
					  }
		}
		
		if(document.getElementById("tabvideos") != null)
		{
			myobj7 = document.getElementById("tabvideos");
			imgsrc7 = myobj7.src;
			if (condition.length == 1)
				{
					
					condition=condition + 'imgsrc7.indexOf("_on.gif")> 0';
				}
				  else {
					  condition=condition + '|| imgsrc7.indexOf("_on.gif")> 0';
					  }
		}
		
		
		
		if (condition)  
		{
			if(document.getElementById("tabsummary") != null)
			{
				myobj1.src = "http://" + location.host + "/work/tabs/summaryoff.gif";
				document.getElementById("summary").style.display = "none";
			}
			if(document.getElementById("tabcomments") != null)
			{
				myobj3.src = "http://" + location.host + "/work/tabs/commentsoff.gif";
				document.getElementById("comments").style.display = "none";
			}
			
			if(document.getElementById("tabphotos") != null)
			{
			myobj4.src = "http://" + location.host + "/work/tabs/photosoff.gif";
			document.getElementById("photos").style.display = "none";
			}
			
			if(document.getElementById("tabbooks") != null)
			{
			myobj5.src = "http://" + location.host + "/work/tabs/booksoff.gif";
			document.getElementById("books").style.display = "none";
			}
			
			if(document.getElementById("tabpuppies") != null)
			{
			myobj6.src = "http://" + location.host + "/work/tabs/puppiesoff.gif";
			document.getElementById("puppies").style.display = "none";
			}
			
			if(document.getElementById("tabvideos") != null)
			{
			myobj7.src = "http://" + location.host + "/work/tabs/videosoff.gif";
			document.getElementById("videos").style.display = "none";
			}
			
			myobj = document.getElementById("tabproducts");
			myobj.src = "http://" + location.host + "/work/tabs/products_on.gif";
			document.getElementById("lproducts").style.display = "block";
			
		}
	}
	
	
	
	if (tabname=='comments') 
	{
	
		condition=' ';
		
		if(document.getElementById("tabsummary") != null)
		{
			myobj1 = document.getElementById("tabsummary");
			imgsrc1 = myobj1.src;
			if (condition.length == 1)
				{
					
					condition=condition + 'imgsrc1.indexOf("_on.gif")> 0';
				}
				  else {
					  condition=condition + '|| imgsrc1.indexOf("_on.gif")> 0';
					  }
		}
		
		if(document.getElementById("tabproducts") != null)
		{
			myobj2 = document.getElementById("tabproducts");
			imgsrc2 = myobj2.src;
			
			if (condition.length ==1)
				{
					
					condition= 'imgsrc2.indexOf("_on.gif")> 0';
				} else {
					condition= '|| imgsrc2.indexOf("_on.gif")> 0';
					}
		}	
		
		if(document.getElementById("tabphotos") != null)
		{
			myobj4 = document.getElementById("tabphotos");
			imgsrc4 = myobj4.src;
			if (condition.length == 1)
				{
					condition=condition + 'imgsrc4.indexOf("_on.gif")> 0';
				}
				  else {
					  condition=condition + '|| imgsrc4.indexOf("_on.gif")> 0';
					  }
		}
		
		if(document.getElementById("tabbooks") != null)
		{
			myobj5 = document.getElementById("tabbooks");
			imgsrc5 = myobj5.src;
			if (condition.length == 1)
				{
					condition=condition + 'imgsrc5.indexOf("_on.gif")> 0';
				}
				  else {
					  condition=condition + '|| imgsrc5.indexOf("_on.gif")> 0';
					  }
		}
		
		if(document.getElementById("tabpuppies") != null)
		{
			myobj6 = document.getElementById("tabpuppies");
			imgsrc6 = myobj6.src;
			if (condition.length == 1)
				{
					condition=condition + 'imgsrc6.indexOf("_on.gif")> 0';
				}
				  else {
					  condition=condition + '|| imgsrc6.indexOf("_on.gif")> 0';
					  }
		}
		
		if(document.getElementById("tabvideos") != null)
		{
			myobj7 = document.getElementById("tabvideos");
			imgsrc7 = myobj7.src;
			if (condition.length == 1)
				{
					
					condition=condition + 'imgsrc7.indexOf("_on.gif")> 0';
				}
				  else {
					  condition=condition + '|| imgsrc7.indexOf("_on.gif")> 0';
					  }
		}
		
		
		
		if (condition)  
		{
			if(document.getElementById("tabsummary") != null)
			{
				myobj1.src = "http://" + location.host + "/work/tabs/summaryoff.gif";
				document.getElementById("summary").style.display = "none";
			}
			if(document.getElementById("tabproducts") != null)
			{
				myobj2.src = "http://" + location.host + "/work/tabs/productsoff.gif";
				document.getElementById("lproducts").style.display = "none";
			}
			
			if(document.getElementById("tabphotos") != null)
			{
			myobj4.src = "http://" + location.host + "/work/tabs/photosoff.gif";
			document.getElementById("photos").style.display = "none";
			}
			
			if(document.getElementById("tabbooks") != null)
			{
			myobj5.src = "http://" + location.host + "/work/tabs/booksoff.gif";
			document.getElementById("books").style.display = "none";
			}
			
			if(document.getElementById("tabpuppies") != null)
			{
			myobj6.src = "http://" + location.host + "/work/tabs/puppiesoff.gif";
			document.getElementById("puppies").style.display = "none";
			}
			
			if(document.getElementById("tabvideos") != null)
			{
			myobj7.src = "http://" + location.host + "/work/tabs/videosoff.gif";
			document.getElementById("videos").style.display = "none";
			}
			
			myobj = document.getElementById("tabcomments");
			myobj.src = "http://" + location.host + "/work/tabs/comments_on.gif";
			document.getElementById("comments").style.display = "block";
			
		}
	}
	
	
	
	if (tabname=='books') 
	{
	
		condition=' ';
		
		if(document.getElementById("tabsummary") != null)
		{
			myobj1 = document.getElementById("tabsummary");
			imgsrc1 = myobj1.src;
			if (condition.length == 1)
				{
					
					condition=condition + 'imgsrc1.indexOf("_on.gif")> 0';
				}
				  else {
					  condition=condition + '|| imgsrc1.indexOf("_on.gif")> 0';
					  }
		}
		
		if(document.getElementById("tabproducts") != null)
		{
			myobj2 = document.getElementById("tabproducts");
			imgsrc2 = myobj2.src;
			
			if (condition.length ==1)
				{
					
					condition= 'imgsrc2.indexOf("_on.gif")> 0';
				} else {
					condition= '|| imgsrc2.indexOf("_on.gif")> 0';
					}
		}	
		
		if(document.getElementById("tabcomments") != null)
		{
			
			myobj3 = document.getElementById("tabcomments");
			imgsrc3 = myobj3.src;
			
			if (condition.length == 1)
				{
					condition=condition + 'imgsrc3.indexOf("_on.gif")> 0';
				}
				  else {
					  condition=condition + '|| imgsrc3.indexOf("_on.gif")> 0';
					  }
		}
		
		if(document.getElementById("tabphotos") != null)
		{
			myobj4 = document.getElementById("tabphotos");
			imgsrc4 = myobj4.src;
			if (condition.length == 1)
				{
					condition=condition + 'imgsrc4.indexOf("_on.gif")> 0';
				}
				  else {
					  condition=condition + '|| imgsrc4.indexOf("_on.gif")> 0';
					  }
		}
		
		
		
		if(document.getElementById("tabpuppies") != null)
		{
			myobj6 = document.getElementById("tabpuppies");
			imgsrc6 = myobj6.src;
			if (condition.length == 1)
				{
					condition=condition + 'imgsrc6.indexOf("_on.gif")> 0';
				}
				  else {
					  condition=condition + '|| imgsrc6.indexOf("_on.gif")> 0';
					  }
		}
		
		if(document.getElementById("tabvideos") != null)
		{
			myobj7 = document.getElementById("tabvideos");
			imgsrc7 = myobj7.src;
			if (condition.length == 1)
				{
					
					condition=condition + 'imgsrc7.indexOf("_on.gif")> 0';
				}
				  else {
					  condition=condition + '|| imgsrc7.indexOf("_on.gif")> 0';
					  }
		}
		
		
		
		if (condition)  
		{
			if(document.getElementById("tabsummary") != null)
			{
				myobj1.src = "http://" + location.host + "/work/tabs/summaryoff.gif";
				document.getElementById("summary").style.display = "none";
			}
			if(document.getElementById("tabproducts") != null)
			{
				myobj2.src = "http://" + location.host + "/work/tabs/productsoff.gif";
				document.getElementById("lproducts").style.display = "none";
			}
			
			if(document.getElementById("tabcomments") != null)
			{
				myobj3.src = "http://" + location.host + "/work/tabs/commentsoff.gif";
				document.getElementById("comments").style.display = "none";
			}
			
			if(document.getElementById("tabphotos") != null)
			{
			myobj4.src = "http://" + location.host + "/work/tabs/photosoff.gif";
			document.getElementById("photos").style.display = "none";
			}
			
			if(document.getElementById("tabpuppies") != null)
			{
			myobj6.src = "http://" + location.host + "/work/tabs/puppiesoff.gif";
			document.getElementById("puppies").style.display = "none";
			}
			
			if(document.getElementById("tabvideos") != null)
			{
			myobj7.src = "http://" + location.host + "/work/tabs/videosoff.gif";
			document.getElementById("videos").style.display = "none";
			}
			
			myobj = document.getElementById("tabbooks");
			myobj.src = "http://" + location.host + "/work/tabs/books_on.gif";
			document.getElementById("books").style.display = "block";
			
		}
	}
	
	
	
	if (tabname=='puppies') 
	{
	
		condition=' ';
		
		if(document.getElementById("tabsummary") != null)
		{
			myobj1 = document.getElementById("tabsummary");
			imgsrc1 = myobj1.src;
			if (condition.length == 1)
				{
					
					condition=condition + 'imgsrc1.indexOf("_on.gif")> 0';
				}
				  else {
					  condition=condition + '|| imgsrc1.indexOf("_on.gif")> 0';
					  }
		}
		
		if(document.getElementById("tabproducts") != null)
		{
			myobj2 = document.getElementById("tabproducts");
			imgsrc2 = myobj2.src;
			
			if (condition.length ==1)
				{
					
					condition= 'imgsrc2.indexOf("_on.gif")> 0';
				} else {
					condition= '|| imgsrc2.indexOf("_on.gif")> 0';
					}
		}	
		
		if(document.getElementById("tabcomments") != null)
		{
			
			myobj3 = document.getElementById("tabcomments");
			imgsrc3 = myobj3.src;
			
			if (condition.length == 1)
				{
					condition=condition + 'imgsrc3.indexOf("_on.gif")> 0';
				}
				  else {
					  condition=condition + '|| imgsrc3.indexOf("_on.gif")> 0';
					  }
		}
		
		if(document.getElementById("tabphotos") != null)
		{
			myobj4 = document.getElementById("tabphotos");
			imgsrc4 = myobj4.src;
			if (condition.length == 1)
				{
					condition=condition + 'imgsrc4.indexOf("_on.gif")> 0';
				}
				  else {
					  condition=condition + '|| imgsrc4.indexOf("_on.gif")> 0';
					  }
		}
		
		
		
		if(document.getElementById("tabbooks") != null)
		{
			myobj5 = document.getElementById("tabbooks");
			imgsrc5 = myobj5.src;
			if (condition.length == 1)
				{
					condition=condition + 'imgsrc5.indexOf("_on.gif")> 0';
				}
				  else {
					  condition=condition + '|| imgsrc5.indexOf("_on.gif")> 0';
					  }
		}
		
		if(document.getElementById("tabvideos") != null)
		{
			myobj7 = document.getElementById("tabvideos");
			imgsrc7 = myobj7.src;
			if (condition.length == 1)
				{
					
					condition=condition + 'imgsrc7.indexOf("_on.gif")> 0';
				}
				  else {
					  condition=condition + '|| imgsrc7.indexOf("_on.gif")> 0';
					  }
		}
		
		
		
		if (condition)  
		{
			if(document.getElementById("tabsummary") != null)
			{
				myobj1.src = "http://" + location.host + "/work/tabs/summaryoff.gif";
				document.getElementById("summary").style.display = "none";
			}
			if(document.getElementById("tabproducts") != null)
			{
				myobj2.src = "http://" + location.host + "/work/tabs/productsoff.gif";
				document.getElementById("lproducts").style.display = "none";
			}
			
			if(document.getElementById("tabcomments") != null)
			{
				myobj3.src = "http://" + location.host + "/work/tabs/commentsoff.gif";
				document.getElementById("comments").style.display = "none";
			}
			
			if(document.getElementById("tabphotos") != null)
			{
			myobj4.src = "http://" + location.host + "/work/tabs/photosoff.gif";
			document.getElementById("photos").style.display = "none";
			}
			
			if(document.getElementById("tabbooks") != null)
			{
			myobj5.src = "http://" + location.host + "/work/tabs/booksoff.gif";
			document.getElementById("books").style.display = "none";
			}
			
			if(document.getElementById("tabvideos") != null)
			{
			myobj7.src = "http://" + location.host + "/work/tabs/videosoff.gif";
			document.getElementById("videos").style.display = "none";
			}
			
			myobj = document.getElementById("tabpuppies");
			myobj.src = "http://" + location.host + "/work/tabs/puppies_on.gif";
			document.getElementById("puppies").style.display = "block";
			
		}
	}
	
	
	
	if (tabname=='photos')
	{
		condition=' ';
		
		if(document.getElementById("tabsummary") != null)
		{
			myobj1 = document.getElementById("tabsummary");
			imgsrc1 = myobj1.src;
			if (condition.length == 1)
				{
					
					condition=condition + 'imgsrc1.indexOf("_on.gif")> 0';
				}
				  else {
					  condition=condition + '|| imgsrc1.indexOf("_on.gif")> 0';
					  }
		}
		
		if(document.getElementById("tabproducts") != null)
		{
			myobj2 = document.getElementById("tabproducts");
			imgsrc2 = myobj2.src;
			
			if (condition.length ==1)
				{
					
					condition= 'imgsrc2.indexOf("_on.gif")> 0';
				} else {
					condition= '|| imgsrc2.indexOf("_on.gif")> 0';
					}
		}	
		
		if(document.getElementById("tabcomments") != null)
		{
			myobj3 = document.getElementById("tabcomments");
			imgsrc3 = myobj3.src;
			
			if (condition.length == 1)
				{
					condition=condition + 'imgsrc3.indexOf("_on.gif")> 0';
				}
				  else {
					  condition=condition + '|| imgsrc3.indexOf("_on.gif")> 0';
					  }
		}
		
		if(document.getElementById("tabbooks") != null)
		{
			myobj5 = document.getElementById("tabbooks");
			imgsrc5 = myobj5.src;
			if (condition.length == 1)
				{
					condition=condition + 'imgsrc5.indexOf("_on.gif")> 0';
				}
				  else {
					  condition=condition + '|| imgsrc5.indexOf("_on.gif")> 0';
					  }
		}
		
		if(document.getElementById("tabpuppies") != null)
		{
			myobj6 = document.getElementById("tabpuppies");
			imgsrc6 = myobj6.src;
			if (condition.length == 1)
				{
					condition=condition + 'imgsrc6.indexOf("_on.gif")> 0';
				}
				  else {
					  condition=condition + '|| imgsrc6.indexOf("_on.gif")> 0';
					  }
		}
		
		if(document.getElementById("tabvideos") != null)
		{
			myobj7 = document.getElementById("tabvideos");
			imgsrc7 = myobj7.src;
			if (condition.length == 1)
				{
					
					condition=condition + 'imgsrc7.indexOf("_on.gif")> 0';
				}
				  else {
					  condition=condition + '|| imgsrc7.indexOf("_on.gif")> 0';
					  }
		}
		
		
		if (condition)  
		{
			
			if(document.getElementById("tabsummary") != null)
			{
				myobj1.src = "http://" + location.host + "/work/tabs/summaryoff.gif";
				document.getElementById("summary").style.display = "none";
			}
			
			if(document.getElementById("tabproducts") != null)
			{
				myobj2.src = "http://" + location.host + "/work/tabs/productsoff.gif";
				document.getElementById("lproducts").style.display = "none";
			}
			
			if(document.getElementById("tabcomments") != null)
			{
				myobj3.src = "http://" + location.host + "/work/tabs/commentsoff.gif";
				document.getElementById("comments").style.display = "none";
			}
			
			if(document.getElementById("tabbooks") != null)
			{
			myobj5.src = "http://" + location.host + "/work/tabs/booksoff.gif";
			document.getElementById("books").style.display = "none";
			}
			
			if(document.getElementById("tabpuppies") != null)
			{
			myobj6.src = "http://" + location.host + "/work/tabs/puppiesoff.gif";
			document.getElementById("puppies").style.display = "none";
			}
			
			if(document.getElementById("tabvideos") != null)
			{
			myobj7.src = "http://" + location.host + "/work/tabs/videosoff.gif";
			document.getElementById("videos").style.display = "none";
			}
			
			myobj = document.getElementById("tabphotos");
			myobj.src = "http://" + location.host + "/work/tabs/photos_on.gif";
			document.getElementById("photos").style.display = "block";
		}	
	}
	
	
	
	
	
	if (tabname=='videos')
	{
		condition=' ';
		
		if(document.getElementById("tabsummary") != null)
		{
			myobj1 = document.getElementById("tabsummary");
			imgsrc1 = myobj1.src;
			if (condition.length == 1)
				{
					
					condition=condition + 'imgsrc1.indexOf("_on.gif")> 0';
				}
				  else {
					  condition=condition + '|| imgsrc1.indexOf("_on.gif")> 0';
					  }
		}
		
		if(document.getElementById("tabproducts") != null)
		{
			myobj2 = document.getElementById("tabproducts");
			imgsrc2 = myobj2.src;
			
			if (condition.length ==1)
				{
					
					condition= 'imgsrc2.indexOf("_on.gif")> 0';
				} else {
					condition= '|| imgsrc2.indexOf("_on.gif")> 0';
					}
		}	
		
		if(document.getElementById("tabcomments") != null)
		{
			myobj3 = document.getElementById("tabcomments");
			imgsrc3 = myobj3.src;
			
			if (condition.length == 1)
				{
					condition=condition + 'imgsrc3.indexOf("_on.gif")> 0';
				}
				  else {
					  condition=condition + '|| imgsrc3.indexOf("_on.gif")> 0';
					  }
		}
		
		if(document.getElementById("tabbooks") != null)
		{
			myobj5 = document.getElementById("tabbooks");
			imgsrc5 = myobj5.src;
			if (condition.length == 1)
				{
					condition=condition + 'imgsrc5.indexOf("_on.gif")> 0';
				}
				  else {
					  condition=condition + '|| imgsrc5.indexOf("_on.gif")> 0';
					  }
		}
		
		if(document.getElementById("tabpuppies") != null)
		{
			myobj6 = document.getElementById("tabpuppies");
			imgsrc6 = myobj6.src;
			if (condition.length == 1)
				{
					condition=condition + 'imgsrc6.indexOf("_on.gif")> 0';
				}
				  else {
					  condition=condition + '|| imgsrc6.indexOf("_on.gif")> 0';
					  }
		}
		
		
		if(document.getElementById("tabphotos") != null)
		{
			myobj4 = document.getElementById("tabphotos");
			imgsrc4 = myobj4.src;
			if (condition.length == 1)
				{
					condition=condition + 'imgsrc4.indexOf("_on.gif")> 0';
				}
				  else {
					  condition=condition + '|| imgsrc4.indexOf("_on.gif")> 0';
					  }
		}
		
		if (condition)  
		{
			
			if(document.getElementById("tabsummary") != null)
			{
				myobj1.src = "http://" + location.host + "/work/tabs/summaryoff.gif";
				document.getElementById("summary").style.display = "none";
			}
			
			if(document.getElementById("tabproducts") != null)
			{
				myobj2.src = "http://" + location.host + "/work/tabs/productsoff.gif";
				document.getElementById("lproducts").style.display = "none";
			}
			
			if(document.getElementById("tabcomments") != null)
			{
				myobj3.src = "http://" + location.host + "/work/tabs/commentsoff.gif";
				document.getElementById("comments").style.display = "none";
			}
			
			if(document.getElementById("tabphotos") != null)
			{
			myobj4.src = "http://" + location.host + "/work/tabs/photosoff.gif";
			document.getElementById("photos").style.display = "none";
			}
			
			if(document.getElementById("tabbooks") != null)
			{
			myobj5.src = "http://" + location.host + "/work/tabs/booksoff.gif";
			document.getElementById("books").style.display = "none";
			}
			
			if(document.getElementById("tabpuppies") != null)
			{
			myobj6.src = "http://" + location.host + "/work/tabs/puppiesoff.gif";
			document.getElementById("puppies").style.display = "none";
			}
			
			myobj = document.getElementById("tabvideos");
			myobj.src = "http://" + location.host + "/work/tabs/videos_on.gif";
			document.getElementById("videos").style.display = "block";
		}	
	}
	
	
	
	
	
	
	
	
	
	
	
	
	
	
	
	
	
	
	
	
	
	
	
	
	
	

	
	
	
	
	
	
	
}

function MM_swapImgRestore() { //v3.0
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}

function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}

function MM_findObj(n, d) { //v4.01
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && d.getElementById) x=d.getElementById(n); return x;
}

function MM_swapImage() { //v3.0
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}
function findItem(n, d) {
	var p,x,i;
	if(!d) d=document;
	if((p=n.indexOf("?"))>0&&parent.frames.length) {
		d=parent.frames[n.substring(p+1)].document;
		n=n.substring(0,p);
	}
	if(!(x=d[n])&&d.all)
		x=d.all[n];
	for (i=0;!x&&i<d.forms.length;i++)
		x=d.forms[i][n];
	for(i=0;!x&&d.layers&&i<d.layers.length;i++)
		x=findItem(n,d.layers[i].document);
	return x;
}
function toggleCategorias(id){
	obj = MM_findObj(id);
	if(typeof(obj.style)!='undefined'){
		if(obj.style.display!='none'){
			obj.style.display = 'none';
			WriteCookie(id.toString(),'off')
		}else{
			obj.style.display = 'block';
			WriteCookie(id.toString(),'on')
		}
	}
}
function toggleAdicionales(id){
	obj = MM_findObj(id);
	if(typeof(obj.style)!='undefined'){
		if(obj.style.display!='none'){
			obj.style.display = 'none';
		}else{
			obj.style.display = 'block';
		}
	}
}
function popup(url,ancho,alto,id,extras){
	if(navigator.userAgent.indexOf("Mac")>0){ancho=ancho+0;alto=alto+0;}
	var left = (screen.availWidth-ancho)/2;
	var top = (screen.availHeight-alto)/2;
	if(extras!=""){extras=","+extras;};
	var ventana = window.open(url,id,'width='+ancho+',height='+alto+',left='+left+',top='+top+',screenX='+left+',screenY='+top+extras);
	if(ventana==null || typeof(ventana.document)=="undefined") alert("Warning:\n\n Please desactive the popup block in your browser.");
}
function trim(str){return str.replace(/^\s*|\s*$/g,"");}

errColor='#8CB2D8' //9F9184
function completo(obj,nombre,tipo){if (tipo=='int'){ if ((trim(obj.value)=='')||(isNaN(obj.value))){obj.style.backgroundColor=errColor;return "\n* "+nombre+" "}else{return "";};}else{ if (trim(obj.value)==''){obj.style.backgroundColor=errColor;return "\n* "+nombre+"."}else{return ""}}}
function emailvalido(obj,nombre) {msg = "";if(obj.value!=""){var reg1 = /(@.*@)|(\.\.)|(@\.)|(\.@)|(^\.)/;var reg2 = /^.+\@(\[?)[a-zA-Z0-9\-\.]+\.([a-zA-Z]{2,3}|[0-9]{1,3})(\]?)$/;if (reg1.test(obj.value) || !reg2.test(obj.value)){obj.style.backgroundColor=errColor;msg= "\n* "+nombre+"."}}else{obj.style.backgroundColor=errColor; msg="\n* "+nombre+" "} return msg}
function telefonovalido(obj,nombre){var reg=/\d{3,}(.?\d{3,})+/; if((obj.value!="")&&!reg.test(obj.value)){obj.style.backgroundColor=errColor;return "\n* "+nombre+" ";}else{return "";}}
function chequeado(obj, nombre){ ok = false; for(i=0; i<obj.length; i++){obj[i].style.backgroundColor=''; if(obj[i].checked){ok = true;};}; if(ok){return ""}else{for(i=0; i<obj.length; i++)obj[i].style.backgroundColor=errColor; return "\n* "+nombre+" "}}
function getCheckedValue(radioObj) {
	if(!radioObj)
		return "undefined::1";
	var radioLength = radioObj.length;
	if(radioLength == undefined)
		if(radioObj.checked)
			return radioObj.value;
		else
			return "undefined::2";
	for(var i = 0; i < radioLength; i++) {
		if(radioObj[i].checked) {
			return radioObj[i].value;
		}
	}
	return "undefined::3";
}

function setCheckedValue(radioObj, newValue) {
	if(!radioObj)
		return;
	var radioLength = radioObj.length;
	if(radioLength == undefined) {
		radioObj.checked = (radioObj.value == newValue.toString());
		return;
	}
	for(var i = 0; i < radioLength; i++) {
		radioObj[i].checked = false;
		if(radioObj[i].value == newValue.toString()) {
			radioObj[i].checked = true;
		}
	}
}
// funciones para cookies
function ReadCookie (name) {
	var namearg = name + "=";
	var nlen = namearg.length;
	var clen = document.cookie.length;
	var i = 0;
	while (i < clen) {
		var j = i + nlen;
		if (document.cookie.substring(i, j) == namearg) {
			var endpos = document.cookie.indexOf (";", j);
			if (endpos == -1) endpos = document.cookie.length;
			return unescape(document.cookie.substring(j, endpos));
		}
		i = document.cookie.indexOf(" ", i) + 1;
		if (i == 0) break;
	}
	return null;
}

function WriteCookie (name, value) {
	var expdate=new Date();
	// expire cookie in 10 years by default
	expdate.setTime(expdate.getTime()+10*365*24*60*60*1000);
	document.cookie = name + "=" + escape (value) + "; expires=" + expdate.toGMTString();
}

// plegado de secciones del menu
function toggle_nav(id){
	obj = MM_findObj(id);
	if(typeof(obj.style)!='undefined'){
		if(obj.style.display!='none'){
			obj.style.display = 'none';
			WriteCookie(id.toString(),'off')
		}else{
			obj.style.display = 'block';
			WriteCookie(id.toString(),'on')
		}
	}
}

function sacarLink(){
	var obj = document.formulario.sitio.value;
	if(obj!=''){
		var tt = obj.indexOf('http://',0);
		if(tt == -1){obj = 'http://'+obj;}
		window.open(obj);
	}
}

function marcame(){
	var d = document.formularioProductos;
	var fld = 'codigoCheck[]';
	var action  =  d['chequearTodos'].checked == true ? 1 : 0 ;
	for (var i=0; i<d.length; i++){
		var obj = d.elements[i]
		var name = obj.name
		if (name == fld){
			obj.checked = ((action==1)? true : ((action==0)? false : !obj.checked) );
		}
	}

}

function ponerMascara(){
	document.getElementById("mascara").style.display="block";
	document.getElementById("ventanita").style.display="block";
}

function bookmarksite(title, url){
if (document.all)
window.external.AddFavorite(url, title);
else if (window.sidebar)
window.sidebar.addPanel(title, url, "")
}
function validar() {
	document.formulario.submit();
}
if(!document.all) document.captureEvents(Event.KEYPRESS);
document.onkeypress = trackKeyPress;
function trackKeyPress(e){
	if(!document.all){
		if(e.which==13) document.formulario.submit();
	}else{
		if(event.keyCode==13) document.formulario.submit();
	}
}

/*
Simple Image Trail script- By JavaScriptKit.com
Visit http://www.javascriptkit.com for this script and more
This notice must stay intact

Script Updated by Dog Up Dev Team. http://wwww.dogup.com/  Your one-stop Dog Spot!
This notice must stay intact
*/

if (document.getElementById || document.all){
	document.write('<div id="trailimageid">');
	document.write('</div>');
}

function gettrailobj(){
if (document.getElementById)
return document.getElementById("trailimageid").style
else if (document.all)
return document.all.trailimagid.style
}

function gettrailobjnostyle(){
if (document.getElementById)
return document.getElementById("trailimageid")
else if (document.all)
return document.all.trailimagid
}

var offsetfrommouse=[0,0]; //image x,y offsets from cursor position in pixels. Enter 0,0 for no offset
var displayduration=0; //duration in seconds image should remain visible. 0 for always.
var currentimageheight = 270;	// maximum image size.

function showbox(media,title,description,showthumb,height,type,wi,he,source){

document.onmousemove=followmouse;

<!-- TYPE: 1- IMAGE / 2-VIDEO   SOURCE: 1-DOGUP / 2-FLICKR  ->
	gettrailobj().width=wi+10+"px";
	gettrailobj().height=he+10+"px";
	
	
	
	<!-- gettrailobj().top="100px" ->
	
	if (type == 2){
	newHTML = '<div id=videobox style="background-image: url(http://www.dogup.com/images/loading.gif) !important;">';
	} else 
	{
	newHTML = '<div id=videobox>';	
	}
	newHTML = newHTML + '<a href="#" onclick="closebox();">Close</a>';

	newHTML = newHTML + '<h2>' + title + '</h2>';
	newHTML = newHTML + description + '<br/>'; 
	newHTML = newHTML + '<div align="center" style="padding: 2px 2px 2px 2px;">';
	if (type == 2){
		
			newHTML = newHTML +	'<object width="'+wi+'" height="'+he+'">';
			newHTML = newHTML + '<param name="movie" value=' + media + '></param>';
			newHTML = newHTML + '<param name="wmode" value="transparent"></param>';
newHTML = newHTML + '<embed src="'+ media +'" type="application/x-shockwave-flash" wmode="transparent" width="'+wi+'" height="'+he+'"></embed>';
newHTML = newHTML + '</object></div>';
    } else {
		
			if (source==1)
			{
			newHTML = newHTML +	'<img src="http://www.dogup.com/uploaded/album/'+media+'" width="'+wi+'" height="'+he+'">';
			} else 
			{
			newHTML = newHTML +	'<img src="'+media+'" width="'+wi+'" height="'+he+'">';	
			}
		}
	newHTML = newHTML + '</div>';
	gettrailobjnostyle().innerHTML = newHTML;
	gettrailobj().display="inline";
}

function closebox(){
	gettrailobj().innerHTML = " ";
	gettrailobj().display="none"
	document.onclick=""
}


function followmouse(e){

	var xcoord=offsetfrommouse[0]
	var ycoord=offsetfrommouse[1]

	var docwidth=document.all? truebody().scrollLeft+truebody().clientWidth : pageXOffset+window.innerWidth-15
	var docheight=document.all? Math.min(truebody().scrollHeight, truebody().clientHeight) : Math.min(window.innerHeight)

	//if (document.all){
	//	gettrailobjnostyle().innerHTML = 'A = ' + truebody().scrollHeight + '<br>B = ' + truebody().clientHeight;
	//} else {
	//	gettrailobjnostyle().innerHTML = 'C = ' + document.body.offsetHeight + '<br>D = ' + window.innerHeight;
	//}

	if (typeof e != "undefined"){
		if (docwidth - e.pageX < 380){
			xcoord = e.pageX - xcoord - 400; // Move to the left side of the cursor
		} else {
			xcoord += e.pageX;
		}
		if (docheight - e.pageY < (currentimageheight + 110)){
			ycoord += e.pageY - Math.max(0,(110 + currentimageheight + e.pageY - docheight - truebody().scrollTop));
		} else {
			ycoord += e.pageY;
		}

	} else if (typeof window.event != "undefined"){
		if (docwidth - event.clientX < 380){
			xcoord = event.clientX + truebody().scrollLeft - xcoord - 400; // Move to the left side of the cursor
		} else {
			xcoord += truebody().scrollLeft+event.clientX
		}
		if (docheight - event.clientY < (currentimageheight + 110)){
			ycoord += event.clientY + truebody().scrollTop - Math.max(0,(110 + currentimageheight + event.clientY - docheight));
		} else {
			ycoord += truebody().scrollTop + event.clientY;
		}
	}

	if(ycoord < 0) { ycoord = ycoord*-1; }
	gettrailobj().left=xcoord+"px"
	gettrailobj().top=ycoord+"px"

}

function makelink(var_id,elem_id,searched){
	var nodeDropdown = document.getElementById(elem_id);
	if(nodeDropdown && nodeDropdown[nodeDropdown.selectedIndex].value != '0') return true;
	if (document.getElementById(var_id) != null){
		var sKeyword = document.getElementById(var_id).value;
		if (/[^\w\-\s]/.test(sKeyword) || sKeyword.search(/\S/)==-1 || !searched) return true;
		sKeyword = sKeyword.replace(/-/g, '_-_');
		sKeyword = sKeyword.replace(/\s+/g, ' ');
		sKeyword = sKeyword.replace(/\s/g, '-');
		var func = typeof(encodeURIComponent) != "undefined" ? encodeURIComponent : escape;
		searched = searched.replace(/SEARCHTERM/g, func(sKeyword));
		location.href = searched;
		return false;
	}
	return true;
}
