//////objects = document.getElementsByTagName("object");
//////for (var i = 0; i < objects.length; i++)
//////{
//////    objects[i].outerHTML = objects[i].outerHTML;
//////}


// SOLUTION 2

//////When the page loads:
////window.onload = function()
////{ 
////  if (document.getElementsByTagName) {
////    var objs = document.getElementsByTagName("object"); //Get all the tags of type object in the page.
////    for (i=0; i<objs.length; i++)
////    {
////      objs[i].outerHTML = objs[i].outerHTML; //Get the HTML content of each object tag and replace it with itself.
////    }
////  }
////}
//////When the page unloads:
////window.onunload = function()
////{
////  if (document.getElementsByTagName) {
////    var objs = document.getElementsByTagName("object"); //Get all the tags of type object in the page.
////    for (i=0; i<objs.length; i++)
////    {
////      objs[i].outerHTML = ""; //Clear out the HTML content of each object tag to prevent an IE memory leak issue.
////    }
////  }
////}

// SOLUTION 3

//////objects = document.getElementsByTagName("object");
//////for (var i = 0; i < objects.length; i++)
//////{
//////    objects[i].outerHTML = objects[i].outerHTML;
//////}


// SOLUTION 2

//////When the page loads:
////window.onload = function()
////{ 
////  if (document.getElementsByTagName) {
////    var objs = document.getElementsByTagName("object"); //Get all the tags of type object in the page.
////    for (i=0; i<objs.length; i++)
////    {
////      objs[i].outerHTML = objs[i].outerHTML; //Get the HTML content of each object tag and replace it with itself.
////    }
////  }
////}
//////When the page unloads:
////window.onunload = function()
////{
////  if (document.getElementsByTagName) {
////    var objs = document.getElementsByTagName("object"); //Get all the tags of type object in the page.
////    for (i=0; i<objs.length; i++)
////    {
////      objs[i].outerHTML = ""; //Clear out the HTML content of each object tag to prevent an IE memory leak issue.
////    }
////  }
////}

// SOLUTION 3

var bo_ns_id = 0;

function startIeFix(){
  if(isIE()){
    document.write('<div id="bo_ns_id_' + bo_ns_id + '"><!-- ');
  }
}

function endIeFix(){
  if(isIE()){
    document.write('</div>');
    var theObject = document.getElementById("bo_ns_id_" + bo_ns_id++);
    var theCode = theObject.innerHTML;
    theCode = theCode.substring(4 ,9+theCode.indexOf("</object>"))
    document.write(theCode);
  }
}

function isIE(){
  var strBrowser = navigator.userAgent.toLowerCase();
  if(strBrowser.indexOf("msie") > -1 && strBrowser.indexOf("mac") < 0){
    return true;
  }else{
    return false;
  }
}

function CopyAddress()
{

window.document.aspnetForm.ctl00$ContentPlaceHolder1$txtShippingName.value=window.document.aspnetForm.ctl00$ContentPlaceHolder1$txtClientName.value +' '+window.document.aspnetForm.ctl00$ContentPlaceHolder1$txtClientSurname.value ;
window.document.aspnetForm.ctl00$ContentPlaceHolder1$txtShippingCity.value=window.document.aspnetForm.ctl00$ContentPlaceHolder1$txtClientCity.value 
window.document.aspnetForm.ctl00$ContentPlaceHolder1$txtShippingAdd.value=window.document.aspnetForm.ctl00$ContentPlaceHolder1$txtClientAdd.value 
window.document.aspnetForm.ctl00$ContentPlaceHolder1$txtShippingZip.value=window.document.aspnetForm.ctl00$ContentPlaceHolder1$txtClientZip.value 
window.document.aspnetForm.ctl00$ContentPlaceHolder1$txtShippingTel.value=window.document.aspnetForm.ctl00$ContentPlaceHolder1$txtClientTel.value 
window.document.aspnetForm.ctl00$ContentPlaceHolder1$txtShippingEmail.value=window.document.aspnetForm.ctl00$ContentPlaceHolder1$txtClientEmail.value 
window.document.aspnetForm.ctl00$ContentPlaceHolder1$txtShippingFax.value='';

}
