I forgot to post the explanation, why the original code does not work:
facesMessages.add("#{messages['registration.success']}", "#{webUser.name}");
When debugging into the seam source I learned, that this cannot work, because
the Interpolator.interpolate() method wil:
examine the given string and try to evaluate all parameters in this string,
which means:
1st: "#{messages['registration.success']}" will be evaluated
the one and only expression in this string is
#{messages['registration.success']}
the evaluation of this string results in this call:
Interpolator.interpolate("#{messages['registration.success']}", null)
which will return "{0} has been registered sucessfully"
because no parameters have been passed to replace the parameter {0}
then this string will be returned to the original Interpolator.interpolate()
function (which has the parameters), but this resulting string will not be
reevaluated, so that the given parameters will never be replaced in my message.
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4100274#4100274
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4100274
_______________________________________________
jboss-user mailing list
[email protected]
https://lists.jboss.org/mailman/listinfo/jboss-user