You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@myfaces.apache.org by "Thomas Andraschko (JIRA)" <de...@myfaces.apache.org> on 2015/10/27 16:20:27 UTC

[jira] [Updated] (MYFACES-3957) Disabled h:commandLink results in rendering of a span with onclick

     [ https://issues.apache.org/jira/browse/MYFACES-3957?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Thomas Andraschko updated MYFACES-3957:
---------------------------------------
    Status: Patch Available  (was: Open)

> Disabled h:commandLink results in rendering of a span with onclick 
> -------------------------------------------------------------------
>
>                 Key: MYFACES-3957
>                 URL: https://issues.apache.org/jira/browse/MYFACES-3957
>             Project: MyFaces Core
>          Issue Type: Bug
>    Affects Versions: 2.0.2
>         Environment: Websphere 8.5
>            Reporter: Stephan Knitelius
>
> {code}
>           <h:commandLink disabled="true" onclick="alert('hello')" type="button">link</h:commandLink>
> AND
>           <h:commandLink disabled="true" onclick="alert('hello')" type="button" value="link" />
> {code}
> Result in:
> {code}
> <span onclick="alert('hello')" type="button">link</span>
> {code}
> I would have expected to find a disabled <a ...></a> or a span without the onclick action.
> In comparison a disabled h:commandButton:
> {code}
> <h:commandButton disabled="true" value="button" onclick="alert('hello')" type="button"/>
> {code}
> Results in:
> {code}
> <input name="frmContent:j_id499838546_62f34114" disabled="disabled" id="frmContent:j_id499838546_62f34114" onclick="alert('hello')" type="button" value="button"></input>
> {code}
> As expected the onclick action is not preformed.
> I would expect similar behaviour from both h:commandButton and h:commandLink.
>  



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)