// Pop-up Window Functions

function openValuePack()
{
	window.open("./supplementary/valuepack.asp","testpopup", "width=320,height=320,scrollbars=yes,status=no,resizable=no" );
}
function openTest()
{
	window.open("./supplementary/popup.html","testpopup", "width=320,height=320,scrollbars=yes,status=no,resizable=no" );
}
function openLogin()
{
	window.open("developer_partner_resources_login.asp", "partnerlogin", "width=300,height=300");
}



// These functions generate mailto links that cannot be harvested by bots.



function mailtoDriver()
{
mailtoSales();
mailtoMarcom();
mailtoBruce();
mailtoKen();
mailtoHR();
mailtoIR();
mailtoWebmaster();
}

function mailtoBruce() {
  var email = "brucer@cardlogix.com";
  
  if (!document.getElementById("mailtoBruce")) return false; // if there is no element that has id="mailToBruce", do not generate this email.
  
  var spanobj = document.getElementById("mailtoBruce"); // The getElementById() method returns a reference to the first object with the specified ID... in this case, it's a [object HTMLSpanElement]
  var anch = document.createElement("a"); // creates an element whose tag is specified by the parameter encased in quotes (i.e. anch is a variable referencing an "a" tag)
  var mailto = "mailto:" + email; // create the mailto string by appending the email variable to the string "mailto:" (i.e. "mailto:brucer@cardlogix.com")
  anch.setAttribute("href",mailto);  // sets the "a" tag (in the anch variable) to have attributes href=mailto, with mailto being the variable containing the string "mailto:brucer@cardlogix.com"
  spanobj.appendChild(anch); // Appends a new childnode to a node
//I think these next two lines generate the visible body text, whereas the previous lines of code created the tag and attributes
  //var txt = document.createTextNode(email); //not sure why createTextNode is called.  I was under the assumption that it was already stored as a string in mailto
  var txt = document.createTextNode(email);
  anch.appendChild(txt); //
}

function mailtoSales() {
  var email = "sales@cardlogix.com";
  
  if (!document.getElementById("mailtoSales")) return false; // if there is no element that has id="mailToBruce", do not generate this email.
  
  var spanobj = document.getElementById("mailtoSales"); // The getElementById() method returns a reference to the first object with the specified ID... in this case, it's a [object HTMLSpanElement]
  var anch = document.createElement("a"); // creates an element whose tag is specified by the parameter encased in quotes (i.e. anch is a variable referencing an "a" tag)
  var mailto = "mailto:" + email; // create the mailto string by appending the email variable to the string "mailto:" (i.e. "mailto:brucer@cardlogix.com")
  anch.setAttribute("href",mailto);  // sets the "a" tag (in the anch variable) to have attributes href=mailto, with mailto being the variable containing the string "mailto:brucer@cardlogix.com"
  spanobj.appendChild(anch); // Appends a new childnode to a node
//I think these next two lines generate the visible body text, whereas the previous lines of code created the tag and attributes
  //var txt = document.createTextNode(email); //not sure why createTextNode is called.  I was under the assumption that it was already stored as a string in mailto
  var txt = document.createTextNode(email);
  anch.appendChild(txt); //
}

function mailtoKen() {
  var email = "ken@cardlogix.com";
  
  if (!document.getElementById("mailtoKen")) return false; // if there is no element that has id="mailToBruce", do not generate this email.
  
  var spanobj = document.getElementById("mailtoKen"); // The getElementById() method returns a reference to the first object with the specified ID... in this case, it's a [object HTMLSpanElement]
  var anch = document.createElement("a"); // creates an element whose tag is specified by the parameter encased in quotes (i.e. anch is a variable referencing an "a" tag)
  var mailto = "mailto:" + email; // create the mailto string by appending the email variable to the string "mailto:" (i.e. "mailto:brucer@cardlogix.com")
  anch.setAttribute("href",mailto);  // sets the "a" tag (in the anch variable) to have attributes href=mailto, with mailto being the variable containing the string "mailto:brucer@cardlogix.com"
  spanobj.appendChild(anch); // Appends a new childnode to a node
//I think these next two lines generate the visible body text, whereas the previous lines of code created the tag and attributes
  //var txt = document.createTextNode(email); //not sure why createTextNode is called.  I was under the assumption that it was already stored as a string in mailto
  var txt = document.createTextNode(email);
  anch.appendChild(txt); //
}

function mailtoHR() {
  var email = "2hr@cardlogix.com";
  
  if (!document.getElementById("mailtoHR")) return false; // if there is no element that has id="mailtoHR", do not generate this email.
  
  var spanobj = document.getElementById("mailtoHR"); // The getElementById() method returns a reference to the first object with the specified ID... in this case, it's a [object HTMLSpanElement]
  var anch = document.createElement("a"); // creates an element whose tag is specified by the parameter encased in quotes (i.e. anch is a variable referencing an "a" tag)
  var mailto = "mailto:" + email; // create the mailto string by appending the email variable to the string "mailto:" (i.e. "mailto:brucer@cardlogix.com")
  anch.setAttribute("href",mailto);  // sets the "a" tag (in the anch variable) to have attributes href=mailto, with mailto being the variable containing the string "mailto:brucer@cardlogix.com"
  spanobj.appendChild(anch); // Appends a new childnode to a node
//I think these next two lines generate the visible body text, whereas the previous lines of code created the tag and attributes
  //var txt = document.createTextNode(email); //not sure why createTextNode is called.  I was under the assumption that it was already stored as a string in mailto
  var txt = document.createTextNode(email);
  anch.appendChild(txt); //
}

function mailtoIR() {
  var email = "2ir@cardlogix.com";
  
  if (!document.getElementById("mailtoIR")) return false; // if there is no element that has id="mailtoIR", do not generate this email.
  
  var spanobj = document.getElementById("mailtoIR"); // The getElementById() method returns a reference to the first object with the specified ID... in this case, it's a [object HTMLSpanElement]
  var anch = document.createElement("a"); // creates an element whose tag is specified by the parameter encased in quotes (i.e. anch is a variable referencing an "a" tag)
  var mailto = "mailto:" + email; // create the mailto string by appending the email variable to the string "mailto:" (i.e. "mailto:brucer@cardlogix.com")
  anch.setAttribute("href",mailto);  // sets the "a" tag (in the anch variable) to have attributes href=mailto, with mailto being the variable containing the string "mailto:brucer@cardlogix.com"
  spanobj.appendChild(anch); // Appends a new childnode to a node
//I think these next two lines generate the visible body text, whereas the previous lines of code created the tag and attributes
  //var txt = document.createTextNode(email); //not sure why createTextNode is called.  I was under the assumption that it was already stored as a string in mailto
  var txt = document.createTextNode(email);
  anch.appendChild(txt); //
}

function mailtoWebmaster() {
  var email = "webhead@cardlogix.com";
  
  if (!document.getElementById("mailtoWebmaster")) return false; // if there is no element that has id="mailtoSales", do not generate this email.
  
  var spanobj = document.getElementById("mailtoWebmaster"); // The getElementById() method returns a reference to the first object with the specified ID... in this case, it's a [object HTMLSpanElement]
  var anch = document.createElement("a"); // creates an element whose tag is specified by the parameter encased in quotes (i.e. anch is a variable referencing an "a" tag)
  var mailto = "mailto:" + email; // create the mailto string by appending the email variable to the string "mailto:" (i.e. "mailto:brucer@cardlogix.com")
  anch.setAttribute("href",mailto);  // sets the "a" tag (in the anch variable) to have attributes href=mailto, with mailto being the variable containing the string "mailto:brucer@cardlogix.com"
  spanobj.appendChild(anch); // Appends a new childnode to a node
//I think these next two lines generate the visible body text, whereas the previous lines of code created the tag and attributes
  //var txt = document.createTextNode(email); //not sure why createTextNode is called.  I was under the assumption that it was already stored as a string in mailto
  var txt = document.createTextNode(email);
  anch.appendChild(txt); //
}

function mailtoMarcom() {
  var email = "marcom@cardlogix.com";
  
  if (!document.getElementById("mailtoMarcom")) return false; // if there is no element that has id="mailtoMarcom", do not generate this email.
  
  var spanobj = document.getElementById("mailtoMarcom"); // The getElementById() method returns a reference to the first object with the specified ID... in this case, it's a [object HTMLSpanElement]
  var anch = document.createElement("a"); // creates an element whose tag is specified by the parameter encased in quotes (i.e. anch is a variable referencing an "a" tag)
  var mailto = "mailto:" + email; // create the mailto string by appending the email variable to the string "mailto:" (i.e. "mailto:brucer@cardlogix.com")
  anch.setAttribute("href",mailto);  // sets the "a" tag (in the anch variable) to have attributes href=mailto, with mailto being the variable containing the string "mailto:brucer@cardlogix.com"
  spanobj.appendChild(anch); // Appends a new childnode to a node
//I think these next two lines generate the visible body text, whereas the previous lines of code created the tag and attributes
  //var txt = document.createTextNode(email); //not sure why createTextNode is called.  I was under the assumption that it was already stored as a string in mailto
  var txt = document.createTextNode(email);
  anch.appendChild(txt); //
}


window.onload = mailtoDriver;