
function gnlformhor(ListID, nlthedomain, thankyoupage, errorpage, btnName) {

//TheCurrentURL = location.href
//nltotallength = location.href.length
//nlthelen = myString.lastIndexOf("/")
//nlCurrentDomain = TheCurrentURL.substring(0,nlthelen+1))

//document.write('<table width="400" border="0" cellspacing="0" cellpadding="0">');
//document.write('<tr>');
//document.write('<td>');

document.write('<form id="form1" name="form1" method="post" action="'+nlthedomain+'nlemailinst.asp">');
document.write('<table width="100%" border="0" cellspacing="0" cellpadding="0">');
document.write('<tr>');
document.write('<td width="40%" align="right" class="nltext">Email&nbsp;&nbsp;</td>');
document.write('<td width="60%"><input type="text" name="nlemailaddress" id="nlemailaddress" class="nlbxemail" />');
rdtopage='+thankyoupage+'
document.write('<input name="liid" type="hidden" id="liid" value="'+ListID+'" />');
document.write('<input name="thankyoupage" type="hidden" id="thankyoupage" value="'+thankyoupage+'" />');
document.write('<input name="errorpage" type="hidden" id="errorpage" value="'+errorpage+'" />');
document.write('<input name="frmsubmit" type="submit" id="frmsubmit" value="'+btnName+'" class="nlbxbtn" /></td>');
document.write('</tr>');
document.write('</table>');
document.write('</form>');
//document.write('</td>');
//document.write('</tr>');
//document.write('</table>');

};



function gnlformver(ListID, nlthedomain, thankyoupage, errorpage, btnName) {
document.write('<table width="140" border="0" cellspacing="0" cellpadding="0">');
document.write('<tr>');
document.write('<td>');
document.write('<form id="form1" name="form1" method="post" action="'+nlthedomain+'nlemailinst.asp">');
document.write('<table width="100%" border="0" cellspacing="0" cellpadding="0">');
document.write('<tr>');
document.write('<td class="nltext"><div style="text-align:left; width:100%;">Email</div></td>');
document.write('</tr>');
document.write('<tr>');
document.write('<td align="left" style="height:20px; vertical-align:middle;"><input type="text" name="nlemailaddress" id="nlemailaddress" class="nlbxemail" /></td>');
document.write('</tr><tr><td class="nltext">');
document.write('<input name="liid" type="hidden" id="liid" value="'+ListID+'" />');
document.write('<input name="thankyoupage" type="hidden" id="thankyoupage" value="'+thankyoupage+'" />');
document.write('<input name="errorpage" type="hidden" id="errorpage" value="'+errorpage+'" />');
document.write('<input name="frmsubmit" type="submit" id="frmsubmit" value="'+btnName+'" class="nlbxbtn" /></td>');
document.write('</tr>');
document.write('</table>');
document.write('</form>');
document.write('</td>');
document.write('</tr>');
document.write('</table>');
};

function gnlformverNET(ListID, nlthedomain, thankyoupage, errorpage, btnName) {
document.write('<table width="140" border="0" cellspacing="0" cellpadding="0">');
document.write('<tr>');
document.write('<td>');
//document.write('<form id="nlform" name="nlform" method="post" action="'+nlthedomain+'nlemailinst.asp">');
document.write('<table width="100%" border="0" cellspacing="0" cellpadding="0">');
document.write('<tr>');
document.write('<td class="nltext"><div style="text-align:left; width:100%;">Please enter your email</div></td>');
document.write('</tr>');
document.write('<tr>');
document.write('<td align="left" style="height:20px; vertical-align:middle;"><input type="text" name="nlemailaddress" id="nlemailaddress" class="nlbxemail" /></td>');
document.write('</tr><tr><td class="nltext">');
document.write('<input name="liid" type="hidden" id="liid" value="'+ListID+'" />');
document.write('<input name="thankyoupage" type="hidden" id="thankyoupage" value="'+thankyoupage+'" />');
document.write('<input name="errorpage" type="hidden" id="errorpage" value="'+errorpage+'" />');
document.write('<input name="frmsubmit" type="button" id="frmsubmit" value="'+btnName+'" class="nlbxbtn" onClick="javascript:submitnewsletterform();" /></td>');
document.write('</tr>');
document.write('</table>');
//document.write('</form>');
document.write('</td>');
document.write('</tr>');
document.write('</table>');
};

function submitnewsletterform() {
document.location.href='http://newsletter.gurus.co.uk/nlemailinst.asp?nlemailaddress='+document.getElementById("nlemailaddress").value+'&frmsubmit=yes&liid='+document.getElementById("liid").value+'&thankyoupage='+document.getElementById("thankyoupage").value+'&errorpage='+document.getElementById("errorpage").value
};




