Linux set the default JDK

In case, there are multiple jdks installed on you linux box and you want to change default JDK. Run the following commands to change the default jdk.

/usr/sbin/alternatives --config java
/usr/sbin/alternatives --config javac
/usr/sbin/alternatives --config java_sdk_1.7.0

Liferay Portlet : trun off portlet namespace prefixed to input field

When we do the portlet development in the Liferay, each input field name and request parameters needs to be prefixed with the portlet namespace.

Portletnamespace prefix is used avoid the conflict, if multiple portlets are dropped on the same page. But if you want to make your portlet work without portlet namespace prefix, it can be done by setting the requires-namespaced-parameters to false in the liferay-portlet.xml file.

<portlet>
	<portlet-name>customportlet</portlet-name>
	<icon>/icon.png</icon>
	<instanceable>false</instanceable>
	<requires-namespaced-parameters>false</requires-namespaced-parameters>
</portlet>