Forums

Home » Liferay Portal » English » Liferay Legacy »

Combination View Flat View Tree View
Threads [ Previous | Next ]
toggle
Fazle Khan
how versitile is the <liferay-ui:error> tag?
September 28, 2006 4:32 PM
Answer

Fazle Khan

Rank: Junior Member

Posts: 26

Join Date: February 7, 2006

Recent Posts

I understand the basic usage of the <liferay-us:error> tag for example I have the following tag on my jsp

<liferay-ui:error exception="<%= EasyStreetUpgradeHelper.RoadSegmentOneMissing.class %>" message="road-segment-one-missing-exception" />

The thing is there are 8 tags that are very similiar that report errors for 8 very simliar pieces of data with 8 seperate 8 messages. I'd prefer to have a single tag and error message for these 8 pieces of data and just pass in text as a parameter when adding the error to the session.

does anyone have suggestion on how to do that? I see one case in the language.properties provided by liferay where it look like they have parameterized thier message because it include {0} and a {1} but I can't seem to get it to work for exceptions.

-fazle
Russ Danner
RE: how versitile is the <liferay-ui:error> tag?
October 3, 2006 9:59 PM
Answer

Russ Danner

Rank: Regular Member

Posts: 149

Join Date: February 6, 2006

Recent Posts

Fazel,

I'd like to help here but at least for me your message doesnt compute emoticon I think your example is missing which would provide a critical piece of information: which tag you are talking about.

Liferay does support localization and parameterized message hence the {0} items in the message definitions.

How do exceptions and jsp tags relate per se?
Jaipanos Thomas
RE: how versitile is the <liferay-ui:error> tag?
January 27, 2012 1:13 PM
Answer

Jaipanos Thomas

Rank: New Member

Posts: 2

Join Date: April 8, 2011

Recent Posts

Russ Danner:
Fazel,

I'd like to help here but at least for me your message doesnt compute emoticon I think your example is missing which would provide a critical piece of information: which tag you are talking about.

Liferay does support localization and parameterized message hence the {0} items in the message definitions.

How do exceptions and jsp tags relate per se?



You mean to say that there is no way we can dipaly an error message with parameter emoticon

I am looking for a way by which i can display error message with parameters using <liferay-ui:error> tag.

How can i add a parameter to SessionErrors

The method SessionErrors.add(PortletRequest portletRequest, String key, Object value) - what is the relevance of Object value . where it can be used?