Remove Default Error Message in Liferay 5.2. SP3

Many time we need to avoid the default error message that come from liferay.

Here is the one trick by which you can avoid default error messages. For this you need to create one hook for customizing Taglib liferay-ui:error.




Here there are two possiblities like

1) You can remove this message from you particular portlet (Or you can say remove message for portlet level)
2) You can remove this message from Portal Level.

For both of this scenario we need to customize end.Jsp of ui- error taglib.
1) To Remove error message from portal level

Inside end,jsp look into the below snippet.



Above condition will display default error message along with custom error message.
If you want hide at portal level than remove


From above code so it will remove default error message for all portlet.
2) To remove default error message for your particulat portlet. Put one condition like this


Above code will remove error message for two portlets only 1) portlet 1 and Portlet 2

Next PostNewer Post Previous PostOlder Post Home