Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Calling jsp page from onclick=""

Status
Not open for further replies.

timmbo

Programmer
Feb 22, 2001
167
US
Is there a way of calling my jsp page, transSearch.jsp from onclick. This is what I have. I'm pretty sure it's not right.

<a href=&quot;#&quot; onclick=&quot;jsp:transSearch.jsp&quot; onmouseover=&quot;window.status='Refine Search.';return true&quot;
onmouseout=&quot;window.status='';return true;&quot;><img src=&quot;isc_nav_refine_search.gif&quot; alt=&quot;Refine Search&quot;
border=&quot;0&quot;></a>

Thanks,
Tim
 
Your jsp page gets requested like any other file on a website.

But you need to use a little javascript to use the onClick event.

<a href=&quot;#&quot; onclick=&quot;self.location.href='transSearch.jsp'&quot; onmouseover=&quot;window.status='Refine Search.';return true&quot;
onmouseout=&quot;window.status='';return true;&quot;><img src=&quot;isc_nav_refine_search.gif&quot; alt=&quot;Refine Search&quot;
border=&quot;0&quot;></a>

Replace &quot;this&quot; with the name of your frame if you are using frames in your html.

Later. I hope this helped! ;-)
- Casey Winans
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top