Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

jsp frames

 
Aparna Ram
Ranch Hand
Posts: 59
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello,

I have a jsp page with 4 frames.
On frame1 is a submit button, clicking on which should allow me to forward the current page on frame2 to another jsp page.

How can I go about doing this?
Kindly guide.

Thanks in advance
Aparna
[ March 20, 2006: Message edited by: Bear Bibeault ]
 
Satish SN
Ranch Hand
Posts: 70
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Aparna

u can achieve what u r trying do with Javascript

for that u need to try to search in the net for following examples it would help u to do

u need to write a javascript function on the submit of third frame to submit the form in the second frame to call the jsp

this is if u r using forms to submit the jsp
document.frames['framename'].formname.submit

this is if u want to simply call the jsp directly
document.frames['framename'].location.href = "xyz.jsp"

u can search the same in net for suitable examples



Satish SN
 
Aparna Ram
Ranch Hand
Posts: 59
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Satish,
Thank you for the reply.
I havent completely understood what you have suggested me. I am quite new to this area.

To make it more clear,
I have 4 frames on one jsp page. frame1, frame2, frame3, frame4.

frame1 is a picture.
frame2 contains the Header.
frame3 is a jsp page that contains a 'SEARCH' Submit button. It uses the servlet named search_results.java
frame4 is a jsp page that already contains an 'ADDUSER' submit button. It uses the servlet named sip_servlet.java


Now when I click on SEARCH button on frame3, I would like the jsp page on frame4 to forward to another jsp page[newjsp.jsp].

According to your suggestion, I am not able to follow where I should create the Javascript function.

Kindly guide me further.
Thanks for your help.

Aparna
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64629
86
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
kumar satish, JavaRanch is a community of people from all over the world, many of who are not native English speakers. While using abbreviations like "u" instead of spelling out "you" is convenient when text messaging your friends on a cell phone or in a chat room, it presents an extra challenge to those that are already struggling with English. Additionally, such shortcuts may confound automated translation tools that patrons of the Ranch may be making use of.

I would like to ask for your help in making the content of JavaRanch a little easier to read for everybody that visits here by not using such abbreviations.

Please read this for more information.

thanks,
bear
JavaRanch Sheriff
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64629
86
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Moved to the HTML forum.
 
Aparna Ram
Ranch Hand
Posts: 59
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Can somebody kindly guide me further?

TIA
Aparna
 
Niki Nono
Ranch Hand
Posts: 256
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
in action attribute of FORM of frame 4 mention the page you want it to go to. then from frame3 call
top.FRAME4NAME.document.submit().
I am not sure about the syntax but i hope you get the idea.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic