cyrilvictor
asked on
passing parameter from java script to crystal report
hello
i want pass a parameter from java script to crystal report. pls c the codeing where i have underlined.plshelp me
the codeing is as follows:
<?php
$code = "<html>";
$code .= "\n\t<head>";
$code .= "\n\t<script language='javascript'>";
$code .= "\n\tfunction BtnClick(par) {";
$code .= "\n\tswitch (par) {";
$code .= "\n\tcase 'Report' :";
$code .= "\n\tlocation.href = './hcfa.rpt';";
-------------------------- ---------- ----
$code .= "\n\tbreak;";
$code .= "\n\tdefault:";
$code .= "\n\talert(par); }";
$code .= "\n\t}";
$code .= "\n\t</script>";
$code .= "\n\t</head>";
$code .= "</table></td></tr></table ><table border=0 cellpadding=0 cellspacing=0 width=100%><tr><td width=100%><table width=100%><tr><td width=50%> </td><td align=center>";
$code .= "<td align=center><img src=./img/report.png name= Export alt='Export HCFA' onclick='BtnClick(\"Report \")'></td> ";
$code .= "</td></tr></table></td></ tr></table ></center> ";
$code .="</html>\n";
echo $code;
i want pass a parameter from java script to crystal report. pls c the codeing where i have underlined.plshelp me
the codeing is as follows:
<?php
$code = "<html>";
$code .= "\n\t<head>";
$code .= "\n\t<script language='javascript'>";
$code .= "\n\tfunction BtnClick(par) {";
$code .= "\n\tswitch (par) {";
$code .= "\n\tcase 'Report' :";
$code .= "\n\tlocation.href = './hcfa.rpt';";
--------------------------
$code .= "\n\tbreak;";
$code .= "\n\tdefault:";
$code .= "\n\talert(par); }";
$code .= "\n\t}";
$code .= "\n\t</script>";
$code .= "\n\t</head>";
$code .= "</table></td></tr></table
$code .= "<td align=center><img src=./img/report.png name= Export alt='Export HCFA' onclick='BtnClick(\"Report
$code .= "</td></tr></table></td></
$code .="</html>\n";
echo $code;
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
$code.= "\n\tlocation.href = './hcfa.rpt?promptex0=para