Where to place code in PR/PM for onclick event of anchor tag <a>
Hi,
I'm trying to provide print option in a popup applet to print only value from specific field which is CLOB. So I have enclosed the field in a <div id='prnArea'></div> and placed an anchor tag <a id='prn' href=# onclick='printDiv('prnArea')'> and the function is defined in a script tag as below.
<script>
function printDiv(divName)
{
var mywindow = window.open('', 'PRINT', 'height=400,width=600);
mywindow.document.write(document.getElementById(divName).innerHTML);
mywindow.document.close();
mywindow.focus();
mywindow.print();
mywindow.close();
return true;}</script>
I've put above code in calculated field but Siebel is stripping the code in the <script> tag. Looks like I have to move the function to PR/PM.