Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>Issues:</p> <ol> <li>IE allows getElementById to be called on fields that have only NAME, no other browsers will allow that, so make sure the form fields have IDs</li> <li>you are calling this onclick of an image inside a link. Not a recommended way. Use onclick of the link and return false</li> <li>Spaces in the OPEN parameters - they can break stuff in some browsers - also <code>target</code> may be a reserved word try </li> </ol> <p>:</p> <pre><code>function openGrpLifeStmtReport (busnsourceid,treatyId,policyid,productid,schemename,periodfrom,periodto,plcyeffdtfrom,polcyeffto,benType,exportTo,jasperName,jasperNamesum,reportvar1,reportvar2,reportvar3,reportvar4,userloged,clientId) { document.getElementById("reportvar1").value = document.getElementById("busnsourceid").value; document.getElementById("reportvar2").value = document.getElementById("treatyId").value; document.getElementById("reportvar4").value = document.getElementById("productid").value; var Busnsourceid=document.getElementById(busnsourceid).value; var TreatyID=document.getElementById(treatyId).value; var PolicyID=document.getElementById(policyid).value; var ProductID=document.getElementById(productid).value; var SchemeName=document.getElementById(schemename).value; var PeriodFrom=document.getElementById(periodfrom).value; var PeriodTo=document.getElementById(periodto).value; var plcyeffdtfrom=document.getElementById(plcyeffdtfrom).value; var polcyeffto=document.getElementById(polcyeffto).value; var BenType=document.getElementById(benType).value; var exportTo=document.getElementById(exportTo).value; var jasperName=document.getElementById(jasperName).value; var jasperNamesum=document.getElementById(jasperNamesum).value; var userloged=document.getElementById(userloged).value; var clientId=document.getElementById(clientId).value; var disorderby = document.getElementById("orderBy").value; var disgroupby = document.getElementById("groupBy").value; var reportvar3=""; var reportvars = document.getElementsByName("reportvar3"); for (var i=0; i &lt; reportvars.length; i++) { if (reportvars[i].checked) { reportvar3 = reportvars[i].value; break; } } var url = "./GroupLifeAdvRep.do?action=customAction&amp;innerAction=printGrpLifeRep&amp;CedantCode="+Busnsourceid+"&amp;TreatyID="+TreatyID+ "&amp;Policy Id="+PolicyID+"&amp;ProductID="+ProductID+"&amp;SchemeName="+SchemeName+"&amp;PeriodFrom="+PeriodFrom+"&amp;PeriodTo="+PeriodTo+"&amp;plcyeffdtfrom="+plcyeffdtfrom+"&amp;polcyeffto="+polcyeffto+"&amp;BenType="+BenType+"&amp;exportTo="+exportTo+"&amp;jasperName="+jasperName+"&amp;jasperNamesum="+jasperNamesum+"&amp;reportvar1="+reportvar1+"&amp;reportvar2="+reportvar2+"&amp;reportvar3="+reportvar3+"&amp;reportvar4="+reportvar4+"&amp;disorderby="+disorderby+"&amp;disgroupby="+disgroupby+"&amp;userloged="+userloged+"&amp;clientId="+clientId; window.open(url,"_blank","width=850,height=600,top=75,left=75,scrollbars,resiza‌​ble"); return false; // cancel link } </code></pre> <p>the code calling this function</p> <pre><code>&lt;a href="#" onclick="return openGrpLifeStmtReport('busnsourceid','treatyId','policyid','productid','schemename','periodfrom','periodto','plcyeffdtfrom','polcyeffto','benType','exportTo','jasperName','jasperNamesum','reportvar1','reportvar2','reportvar3','reportvar4','userloged','clientId')"&gt;&lt;img src="Images/generatereport_btn.gif" alt="generatereport" border="0" /&gt;&lt;/a&gt; </code></pre>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload