[opencms-dev] Accessing Module Parameters from a .jsp File in opencms 5.0

Joachim Arrasz info at arrasz.de
Fri Feb 24 11:22:23 CET 2006


Hi Manuel,

> i want to read a module parameter which i defined in the module
> administartion view, inside a .jsp file.

   /**
     * Method finds value of a ModuleParameter of a specified Module.
     *
     * @param moduleName
     *            String the name of the module
     * @param moduleParameter
     *            String the name of the parameter to read
     * @param cms
     *            the cmsObject
     * @return String the parameter as String Value
     */
    public static String getModuleParameter(final String moduleName,
            final String moduleParameter, final CmsObject cms) {
        String parameter = null;
        CmsModule buf = OpenCms.getModuleManager().getModule(moduleName);
        parameter = buf.getParameter(moduleParameter);
        return parameter;
    }

hth

Regards Achim




More information about the opencms-dev mailing list