[seam-issues] [JBoss JIRA] Commented: (JBSEAM-4641) Including EL in ID for Components Yields "Empty id attribute is not allowed" Exception

Steve Wells (JIRA) jira-events at lists.jboss.org
Fri Apr 23 16:07:10 EDT 2010


    [ https://jira.jboss.org/jira/browse/JBSEAM-4641?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12527374#action_12527374 ] 

Steve Wells commented on JBSEAM-4641:
-------------------------------------

One other observation - when hardwiring the ID's i.e. "id="xyz" the IDs are still tied to JSF generated IDs in the generated HTML:

id="j_id138:0:xyz" name="j_id138:0:xyz"

> Including EL in ID for Components Yields "Empty id attribute is not allowed" Exception
> --------------------------------------------------------------------------------------
>
>                 Key: JBSEAM-4641
>                 URL: https://jira.jboss.org/jira/browse/JBSEAM-4641
>             Project: Seam
>          Issue Type: Bug
>          Components: EL, JSF Integration
>    Affects Versions: 2.2.1.CR1
>         Environment: Linux Server Side, Windows + IE 8 Client Side
>            Reporter: Steve Wells
>
> When specifying an ID for a control (seems to affect all / near all) using an EL expression, it doesn't matter what the EL expression method returns, the following exception is generated.
> EXAMPLE
> <h:outputLink value="http://www.jboss.org" id="#{x.id}">LINK</h:outputLink>  <!-- the x.id() method returns "123", etc. -->
> <h:outputLink value="http://www.jboss.org" id="XXXX#{x.id}">LINK</h:outputLink> <!-- the XXXX prefix doesn't even get it to pass -->
> SEVERE [facelets.viewhandler] Error Rendering View[/test.xhtml]
> java.lang.IllegalArgumentException: Empty id attribute is not allowed
>         at javax.faces.component.UIComponentBase.validateId(UIComponentBase.java:539)
>         at javax.faces.component.UIComponentBase.setId(UIComponentBase.java:366)
>         at com.sun.facelets.tag.jsf.ComponentHandler.apply(ComponentHandler.java:151)
>         at com.sun.facelets.tag.CompositeFaceletHandler.apply(CompositeFaceletHandler.java:47)
>         at com.sun.facelets.tag.jsf.ComponentHandler.applyNextHandler(ComponentHandler.java:314)
>         at com.sun.facelets.tag.jsf.ComponentHandler.apply(ComponentHandler.java:169)
>         at com.sun.facelets.tag.ui.CompositionHandler.apply(CompositionHandler.java:119)
>         at com.sun.facelets.compiler.NamespaceHandler.apply(NamespaceHandler.java:49)
>         at com.sun.facelets.compiler.EncodingHandler.apply(EncodingHandler.java:25)
>         at com.sun.facelets.impl.DefaultFacelet.include(DefaultFacelet.java:248)
>         at com.sun.facelets.impl.DefaultFacelet.include(DefaultFacelet.java:294)
>         at com.sun.facelets.impl.DefaultFacelet.include(DefaultFacelet.java:273)
>         at com.sun.facelets.impl.DefaultFaceletContext.includeFacelet(DefaultFaceletContext.java:140)
>         at com.sun.facelets.tag.ui.IncludeHandler.apply(IncludeHandler.java:65)
>         at com.sun.facelets.tag.CompositeFaceletHandler.apply(CompositeFaceletHandler.java:47)
>         at com.sun.facelets.tag.ui.CompositionHandler.apply(CompositionHandler.java:119)
>         at com.sun.facelets.compiler.NamespaceHandler.apply(NamespaceHandler.java:49)
>         at com.sun.facelets.compiler.EncodingHandler.apply(EncodingHandler.java:25)
>         at com.sun.facelets.impl.DefaultFacelet.include(DefaultFacelet.java:248)
>         at com.sun.facelets.impl.DefaultFacelet.include(DefaultFacelet.java:294)
>         at com.sun.facelets.impl.DefaultFacelet.include(DefaultFacelet.java:273)
>         at com.sun.facelets.impl.DefaultFaceletContext.includeFacelet(DefaultFaceletContext.java:140)
>         at com.sun.facelets.tag.ui.IncludeHandler.apply(IncludeHandler.java:65)
>         at com.sun.facelets.tag.CompositeFaceletHandler.apply(CompositeFaceletHandler.java:47)
>         at com.sun.facelets.tag.jsf.core.ViewHandler.apply(ViewHandler.java:109)
>         at com.sun.facelets.tag.CompositeFaceletHandler.apply(CompositeFaceletHandler.java:47)
>         at com.sun.facelets.compiler.NamespaceHandler.apply(NamespaceHandler.java:49)
>         at com.sun.facelets.tag.CompositeFaceletHandler.apply(CompositeFaceletHandler.java:47)
>         at com.sun.facelets.compiler.EncodingHandler.apply(EncodingHandler.java:25)
>         at com.sun.facelets.impl.DefaultFacelet.include(DefaultFacelet.java:248)
>         at com.sun.facelets.impl.DefaultFacelet.include(DefaultFacelet.java:294)
>         at com.sun.facelets.impl.DefaultFacelet.include(DefaultFacelet.java:273)
>         at com.sun.facelets.impl.DefaultFaceletContext.includeFacelet(DefaultFaceletContext.java:140)
>         at com.sun.facelets.tag.ui.CompositionHandler.apply(CompositionHandler.java:113)
>         at com.sun.facelets.compiler.NamespaceHandler.apply(NamespaceHandler.java:49)
>         at com.sun.facelets.compiler.EncodingHandler.apply(EncodingHandler.java:25)
>         at com.sun.facelets.impl.DefaultFacelet.include(DefaultFacelet.java:248)
>         at com.sun.facelets.impl.DefaultFacelet.include(DefaultFacelet.java:294)
>         at com.sun.facelets.impl.DefaultFacelet.include(DefaultFacelet.java:273)
>         at com.sun.facelets.impl.DefaultFaceletContext.includeFacelet(DefaultFaceletContext.java:140)
>         at com.sun.facelets.tag.ui.CompositionHandler.apply(CompositionHandler.java:113)
>         at com.sun.facelets.compiler.NamespaceHandler.apply(NamespaceHandler.java:49)
>         at com.sun.facelets.compiler.EncodingHandler.apply(EncodingHandler.java:25)
>         at com.sun.facelets.impl.DefaultFacelet.apply(DefaultFacelet.java:95)
>         at com.sun.facelets.FaceletViewHandler.buildView(FaceletViewHandler.java:524)
>         at com.sun.facelets.FaceletViewHandler.renderView(FaceletViewHandler.java:567)
>         at com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:127)
>         at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:101)
>         at com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:139)
>         at javax.faces.webapp.FacesServlet.service(FacesServlet.java:311)
>         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
>         at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>         at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:83)
>         at org.jboss.seam.web.LoggingFilter.doFilter(LoggingFilter.java:60)
>         at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
>         at org.jboss.seam.web.IdentityFilter.doFilter(IdentityFilter.java:40)
>         at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
>         at org.jboss.seam.web.MultipartFilter.doFilter(MultipartFilter.java:90)
>         at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
>         at org.jboss.seam.web.ExceptionFilter.doFilter(ExceptionFilter.java:64)
>         at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
>         at org.jboss.seam.web.RedirectFilter.doFilter(RedirectFilter.java:45)
>         at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
>         at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:73)
>         at org.jboss.seam.servlet.SeamFilter.doFilter(SeamFilter.java:158)
>         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
>         at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>         at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
>         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
>         at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>         at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)
>         at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
>         at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:183)
>         at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:433)
>         at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:95)
>         at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
>         at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
>         at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
>         at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
>         at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
>         at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
>         at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
>         at org.apache.coyote.ajp.AjpAprProcessor.process(AjpAprProcessor.java:419)
>         at org.apache.coyote.ajp.AjpAprProtocol$AjpConnectionHandler.process(AjpAprProtocol.java:402)
>         at org.apache.tomcat.util.net.AprEndpoint$Worker.run(AprEndpoint.java:2036)
>         at java.lang.Thread.run(Thread.java:619)

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        


More information about the seam-issues mailing list