Click to See Complete Forum and Search --> : jsp and 2 javascript statements


chris davies
10-20-2003, 10:13 AM
hi
i need to open the following jsp statement in a pop up window

<a href="javascript:gotoTermsByName('<%=response.encodeURL("Terms")%>',document.editform,'<%=column.getColumnName()%>',','<%="f_" + column.getColumnName().toLowerCase()%>')">Terms List</a>

and i'm also using the follwoing javascript statement

<a href="javascript:windowHandle = window.open('popupwin.html','myExample4','width=500,height=500'); windowHandle.focus()">Example 4</a>


noramlly i would put the ; between the two javascript statements but it doesn't seem to be working.

how do i combine them ?

cheers

chris

fredmv
10-20-2003, 10:16 AM
You should really be doing this inside the onclick event handler of the link. For example:<a href="#" onclick="windowHandle=window.open('popupwin.html','myExample4','width=500,height=500');windowHandle.focus();">Example 4</a> Good luck.

Edited: Also note that it should all be one one line.

chris davies
10-20-2003, 10:56 AM
thanks

i've tried this which works ok to an extent -

<a href="javascript:gotoTermsByName('<%=response.encodeURL("Terms")%>',document.editform,'<%=column.getColumnName()%>','<%="f_" + column.getColumnName().toLowerCase()%>')" onclick="windowHandle=window.open('popupwin. html','myExample4','width=500,height=500');windowHandle.focus();">Terms List</a>

it opens the popupwin.html with this error message

No such action popupwin. html.
Error caused by: java.lang.ClassNotFoundException: com/opentext/basis/webtop/actions/popupwin/ html

and then proceeds to open the second page of an unspecified widht and height ?

any ideas ?

cheers

chris