• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Tim Cooke
  • Campbell Ritchie
  • paul wheaton
  • Ron McLeod
  • Devaka Cooray
Sheriffs:
  • Jeanne Boyarsky
  • Liutauras Vilda
  • Paul Clapham
Saloon Keepers:
  • Tim Holloway
  • Carey Brown
  • Piet Souris
Bartenders:

conditionally targetting the client frame based on Server(servlet) program

 
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi..
I have 2 frames in my page. The first frame is Login frame. Second frame is Error frame.
Login frame having login form with 2 textboxes.. username and password & a submit button. I m submitting form information to a servlet. In the servlet i have to decision of where(to which frame) to send response.If username and password are matches to some particular values,then a response as "Login Success" has to be send to login frame(first frame itself).

If the username or password are not matched to the specific values, then a response with error message "Login failure.. User name u entered is Incorrect" has to be send to Error frame(second frame).

I m giviing a target for the form tag.Its a static target. But here my problem is.. server program has to take decision in which frame response has to be sent.

So pls help me regarding this.
 
author
Posts: 288
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Why not use some hidden fields to distinguish where the request came from along with sendRedirect.
 
Polireddy Vanukuri
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks for ur response.
But there is no argument for sendRedirect() or forward() to specify the target(frame name) of the page.For these methods. we will specify URL of the page which has to be sent as response.But how can the servlet can specify the target frame in those methods?

Help me in this context clearly.
 
Sheriff
Posts: 14691
16
Eclipse IDE VI Editor Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I'm tempted to say : don't use frames
That's an old concept and might be not used around anymore.
(sorry it doesn't help)
 
Polireddy Vanukuri
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
If so, Pls tell me the correct way for my application..
 
Sheriff
Posts: 13411
Firefox Browser VI Editor Redhat
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic