Win a copy of Mesos in Action this week in the Cloud/Virtualizaton forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

How to call a JSP file within a JavaScript file

 
Tony Evans
Ranch Hand
Posts: 598
1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have a javascript program where when I click on a image on mouseup to fire of a function openDashboard that will fire of a page.
document.write("onmouseUp=\"this.className='imgbout';openDashboard(1,1,1,1,1)"");
This function, which is a javascipt function, is in another file a JSP file : detail2.jsp.
What I need to know is how do you include a jsp file in a js file so that my js application can call the openDashboard function.
Thanks for any help.
Cheers Tony
 
Tony Evans
Ranch Hand
Posts: 598
1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have changed the code to be :
document.write("onmouseUp=\"this.className='imgbout';parent.frames['detail']openDashboard(1,2,25,850,550)\"");
Still cant get it to work.
Trying to figure out the syntax.
 
Eric Pascarello
author
Rancher
Posts: 15385
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
.....'detail']openDashboard.....
should be
.....'detail'].openDashboard.....
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic