Stopping PEBKAC in Sun's JSF Impl

From: Ed Burns <>
Date: Tue, 1 Aug 2006 05:59:10 -0700


JSF Impl issue 365 [1] brings up a PEBKAC [2] issue. If the user does
the following three things:

1. have an h:form with prependId=false
2. have an h:commandButton with an id of "submit" or "reset"
3. have one or more h:commandLink tags in the same form as 1

Then, the commandLinks will not work. This is correct JavaScript
behavior. [3]

If the user does this:

1. have an h:commandLink in the page outside of an h:form

Then the commandLink will not work. This is correct behavior.

These two scenarios are examples of PEBKAC [2]. How we deal with PEBKAC
is a matter of choice, and I think it should be done in a consistent
manner. Therefore, I recommend the following action be taken in these
two scenarios.

1. If either scenario is detected, log a message.

2. If the user has java.beans.Beans.isDesignTime() set to true, the text
of the commandLink in question should include the text of the log
message, rendered in an obvious and annoying way, perhaps with the
<blink> tag or similar.

What do you all think, JSF developers?




[3] left as an exercise to the reader

|  | {home: 407 869 9587, office: 408 884 9519 OR x31640}
| homepage:         |
| aim: edburns0sunw | iim: