Adding and getting init parameters
We will be adding the init parameters in the portal.xml as
<init-param>
<name>Height</name>
<value>200</value>
</init-param>
String name = getInitParameter("Height"); //200
Enumeration<String> names = getInitparameterNames(); // It gives the all init parameters
In JSP
portletConfig.getInitParameter("Height");
<init-param>
<name>Height</name>
<value>200</value>
</init-param>
String name = getInitParameter("Height"); //200
Enumeration<String> names = getInitparameterNames(); // It gives the all init parameters
In JSP
portletConfig.getInitParameter("Height");
Comments
Post a Comment