R
RigasMinho
I'm trying to load a java properties file and then read from that file.
But each time I try this it returns the value of Null.
Any Ideas?
String osname;
Properties prop = System.getProperties();
osname = prop.getProperty("os.name");
iff (osname.equals("Windows XP"))
{
prop.getClass().getResourceAsStream("Administration.properties");
}
strServername = prop.getProperty("servername");
%>
This is my JSP page. <%= strServername %><br>
----------
So in the properties file there's a line that says:
"servername=10.10.10.10"
It technically should load up the ip address on the web app page. The
properties file is setup right.
I'm using Tomcat right now.
But each time I try this it returns the value of Null.
Any Ideas?
String osname;
Properties prop = System.getProperties();
osname = prop.getProperty("os.name");
iff (osname.equals("Windows XP"))
{
prop.getClass().getResourceAsStream("Administration.properties");
}
strServername = prop.getProperty("servername");
%>
This is my JSP page. <%= strServername %><br>
----------
So in the properties file there's a line that says:
"servername=10.10.10.10"
It technically should load up the ip address on the web app page. The
properties file is setup right.
I'm using Tomcat right now.