request is not defined

R

Rosebud

I am sure this issue has be addressed in this group before. But, I
could not find an answer in my searching. So, I will ask it now.

I have the following code:
<html>
<head>
<title></title>
<meta name="GENERATOR" content="Microsoft Visual Studio.NET 7.0">
<meta name="vs_targetSchema"
content="http://schemas.microsoft.com/intellisense/ie5">
<SCRIPT id="clientEventHandlersJS" language="javascript">
function Home_onclick()
{
request.getParameter("locale")
parent.main.location="HomeInfoMain.htm"
}
The error I keep getting is that "request is undefined."

Any help on this matter would be appreciated.
 
P

Peter Kirk

I have the following code:
<SCRIPT id="clientEventHandlersJS" language="javascript">
function Home_onclick()
{
request.getParameter("locale")
parent.main.location="HomeInfoMain.htm"
}
The error I keep getting is that "request is undefined."

Any help on this matter would be appreciated.

Are you mixing JAVA and JAVASCRIPT?
I know that on a JSP there is a "request" variable you can access, but I
don't know if the same is true of javascript.

Peter
 
R

Rosebud

Peter Kirk said:
Are you mixing JAVA and JAVASCRIPT?
I know that on a JSP there is a "request" variable you can access, but I
don't know if the same is true of javascript.

Peter

I am a neophyte with jsp. So, that is probably the case. I do want
to retreive the url parameter. So, if anyone could let me know what I
should do then I would be happy about it.
 
M

mromarkhan

Do you mean
<%=request.getParameter("locals..
I meant
<%=request.getParameter("locale")%>

notice the escape used by the jsp processor
<% %>

by the way there is also
<%=request.getLocale()%>

moreover you do need seem to use the value in your code

Have a good day.
peace.
 
R

Rosebud

Do you mean
<%=request.getParameter("locals..
I meant
<%=request.getParameter("locale")%>

notice the escape used by the jsp processor
<% %>

by the way there is also
<%=request.getLocale()%>

moreover you do need seem to use the value in your code

Have a good day.
peace.

thanks. But, the code I showed was just to show the request problem.
In the end I want to use the value to finish various statements.

such as: <!--#include file
="FreeReports<%=request.getParameter("locale")%>.htm" -->

this cause an error that says [an error occurred while processing this
directive]

any ideas?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,055
Latest member
SlimSparkKetoACVReview

Latest Threads

Top