Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

JSP QueryString Problem

Posted on 2001-07-21
4
Medium Priority
?
291 Views
Last Modified: 2006-11-17
Hello,
I am using Tomcat 3.21 for JSP.
I am facing a problem with jsp. I want to send some information to other jsp page.
When I use a url like this in frame src:

<FRAME SRC="displayMessages.jsp#current?rn=<%=roomname%>" name="MessageWin">

other page is unable to retrive querystring value and
request.getParamter("rn") returns null

Then I have to use url like this to get that querystring value

<FRAME SRC="displayMessages.jsp?rn=<%=roomname%>" name="MessageWin">

I have to remove #current from the src attribute.
I want to include #current becuase I want to scroll page down to appropriate
place on displayMessage.jsp.

Is there any solution to this problem.

Sukhwinder Singh  
 

 


   

0
Comment
Question by:Sukhwinder Singh
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
4 Comments
 
LVL 15

Accepted Solution

by:
a.marsh earned 150 total points
ID: 6305403
I would recommend leaving the #current out.

What you can do is add this to the <body> tag of the page displayed after the form submission:

onload="window.location.hash = 'current';"

:o)

Ant
0
 

Author Comment

by:Sukhwinder Singh
ID: 6305461
It means there is problem with JSP engine....
Is it?

OK I'll try it and then tell you I think it'll work.........
0
 
LVL 15

Expert Comment

by:a.marsh
ID: 6305827
Not sure - but if you think about it there should never be this kind of "situation" with a URL as you would normally submit details via a form and then there would never be a #current.

:o)

Ant
0
 

Author Comment

by:Sukhwinder Singh
ID: 6319700
Your method work but I have also found a solution to my problem...
It will work if we write like this
<FRAME SRC="displayMessages.jsp?rn=<%=roomname%>#current" name="MessageWin">
0

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In this post we will learn different types of Android Layout and some basics of an Android App.
Basic understanding on "OO- Object Orientation" is needed for designing a logical solution to solve a problem. Basic OOAD is a prerequisite for a coder to ensure that they follow the basic design of OO. This would help developers to understand the b…
Viewers learn about the scanner class in this video and are introduced to receiving user input for their programs. Additionally, objects, conditional statements, and loops are used to help reinforce the concepts. Introduce Scanner class: Importing…
Viewers will learn how to properly install Eclipse with the necessary JDK, and will take a look at an introductory Java program. Download Eclipse installation zip file: Extract files from zip file: Download and install JDK 8: Open Eclipse and …
Suggested Courses

609 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question