P
Per Magnus L?vold
Hi, all!
I have a series of JSP pages wich connect to an Oracle DB using JDBC.
Several of these pages use the same connection string for JDBC, and
now that the connection parameters change, I have to uådate every one
of them.
So now I am trying to set the parameters in an included file, so I
only have to keep one file up-to-date.
I've searched the web and newsgroups, and found several tips, but none
have worked for me. One specific I am trying to make work is this:
*** file with parameters (test.jsp) ***
<%
request.setAttribute("test", "Display this");
%>
*** end file w params ***
*** main file (main.jsp) ***
<html>
<head></head>
<body>
<%@include file="test.jsp"%>
The test parameter is: <%= test %>.<br>
</body>
</html>
*** end main file ***
This won't compile. I get the error message
"variable test not found in class _main"
I can't see why this shouldn't work. Any ideas how to make this work?
Regards, Per Magnus
I have a series of JSP pages wich connect to an Oracle DB using JDBC.
Several of these pages use the same connection string for JDBC, and
now that the connection parameters change, I have to uådate every one
of them.
So now I am trying to set the parameters in an included file, so I
only have to keep one file up-to-date.
I've searched the web and newsgroups, and found several tips, but none
have worked for me. One specific I am trying to make work is this:
*** file with parameters (test.jsp) ***
<%
request.setAttribute("test", "Display this");
%>
*** end file w params ***
*** main file (main.jsp) ***
<html>
<head></head>
<body>
<%@include file="test.jsp"%>
The test parameter is: <%= test %>.<br>
</body>
</html>
*** end main file ***
This won't compile. I get the error message
"variable test not found in class _main"
I can't see why this shouldn't work. Any ideas how to make this work?
Regards, Per Magnus