>From: Ryan Wynn <[EMAIL PROTECTED]> 
>
> I just upgraded to struts-shale-20060117 and I think I may have found 
> a bug. I am now getting an exception 
> 
> component identifier's first character must be a letter or an 
> underscore ('_')! But it is "@" 
>
>
><span jsfid="kaolin:genderChooser" kaolinId="personGenderId"
>   managed-bean-name="person">
>
><component jsfid="kaolin:genderChooser" extends="t:selectOneMenu"
>     allowBody="false" id="@kaolinId">
>     ....
></component>
>
> 
> 
> The weird thing is that I have other components that declare the id as 
> a symbol like above and they work. I just have a problem with this 
> one. I ran the code through the debugger and noticed that the 
> clayContext does not get kaolinId=personGenderId in it's symbol map at 
> the time of CreateComponentCommand execute. But the display element's 
> symbol map does contain the symbol kaolinId=personGenderId. The 
> problem is that replaceMnemonic uses the symbol map from the 
> clayContext and not from the displayElement. 
> 
> Any ideas why this would have worked before but not now? Did 
> something change that I am not aware of? 

I made some changes that will be in tonights build that has to do with 
how the property values are pushed to the components but it won't 
be in the 0117 nightly.

Try adding a span that spans your span :-)
<span jsfid="subview" managed-bean-name="person" kaolinId="personGenderId">
     <span jsfid="kaolin:genderChooser"/>
</span>

I think that should fix it for now.  It looks like the symbol table is built 
after
the component id is set which works for the rest of the attributes.  The symbol
"kaolinId" is assigned to the component that is being created so it doesn't 
already exist in the context.

The id has to be set before the component can be added to the component tree and
it seems like the component has to be added to the tree to allow binding value 
attributes
to be set (not 100% on the last part of that one).  

But, we can move up the logic that builds the symbol table prior to resolving 
the
component id.  

I agree that this is a bug and hopefully my diagnosis is correct.  Please file 
a 
bugzilla ticket on this one.

> 
> Thanks, 
> Ryan 

Gary

Reply via email to