reading weblogic.properties file

Discussions

Web tier: servlets, JSP, Web frameworks: reading weblogic.properties file

  1. reading weblogic.properties file (1 messages)

    I want to read weblogic.properties file from my jsp. I am using weblogic 4.5.1 server. I will appreciate your help.If you have any code, please mail it to arun_dar at yahoo dot com
    Thanks
    Arun
  2. reading weblogic.properties file[ Go to top ]

    Use this scriplet code -

    <%
            // Initialize your weblogic.properties filename here
            public static final WEBLOGIC_PROP_FILE = "weblogic.properties";
            Properties props = new Properties();
            FileInputStream in = null;
            try {
                in = new FileInputStream(WEBLOGIC_PROP_FILE);
                props.load(in);
            } finally {
                if (in != null) {
                    in.close();
                }
            }
            // Now read the file using props.getProperty()
    %>