You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by "Binkley, Peter" <Pe...@ualberta.ca> on 2005/03/15 20:27:05 UTC

class widgets

I'm starting to get into class widgets in Cocoon Forms, and I'm not sure if my problem fits their use. 

I have an XML structure in which several elements have an identical set of four optional attributes, as well as their own unique attributes. I've declared a widget class containing the four common attributes, and I'd like to instantiate it in all the contexts that need it.

The problem is that when I set this up, I get this error: 

org.apache.cocoon.ProcessingException: Failed to execute pipeline.: org.xml.sax.SAXException: EffectFormTemplateTransformer: Missing required widget "id" attribute.

My <fd:class> element contains only an <fd:widgets> element, containing several fields; the <fb:class> and <ft:class> are similar. The <fd:new> element sits in the <fd:widgets> element of an <fd:repeater>, at the end of the list of <fd:field> elements that are unique to that item; likewise for <fb:new> and <ft:new>. I'm not using union or struct elements. 

The other fields do include an "id" field, and everything works if I comment out the class and new elements, so my basic structure is ok.

Is my use of the class widget to add fields to a context that also defines some of its own fields illegitimate? Is there another way to tackle this problem? Any help would be greatly appreciated.

Peter Binkley
peter.binkley@ualberta.ca




Re: class widgets

Posted by Tim Larson <ti...@keow.org>.
On Tue, Mar 15, 2005 at 12:27:05PM -0700, Binkley, Peter wrote:
> I'm starting to get into class widgets in Cocoon Forms,
> and I'm not sure if my problem fits their use. 
<snip/>

Could you either post a sample of your code here or pop
into the #cocoon IRC channel and pastebot a sample there?

--Tim Larson

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Re: class widgets

Posted by beatejung <be...@online.de>.
hallo peter, 

Am Dienstag, 15. März 2005 20:27 schrieb Binkley, Peter:
> I'm starting to get into class widgets in Cocoon Forms, and I'm not sure if
> my problem fits their use.
>
> I have an XML structure in which several elements have an identical set of
> four optional attributes, as well as their own unique attributes. I've
> declared a widget class containing the four common attributes, and I'd like
> to instantiate it in all the contexts that need it.
>
> The problem is that when I set this up, I get this error:


> org.apache.cocoon.ProcessingException: Failed to execute pipeline.:
> org.xml.sax.SAXException: EffectFormTemplateTransformer: Missing required
> widget "id" attribute.

> My <fd:class> element contains only an <fd:widgets> element, containing
> several fields; the <fb:class> and <ft:class> are similar. The <fd:new>
> element sits in the <fd:widgets> element of an <fd:repeater>, at the end of
> the list of <fd:field> elements that are unique to that item; likewise for
> <fb:new> and <ft:new>. I'm not using union or struct elements.
>


the error message means the id attribute, not a field i think. 
check if you wrote it like this:	<ft:class id="question-para">
perhaps a wrong character somewhere in the head of the class template 
definition or not lower case ?

> Is my use of the class widget to add fields to a context that also defines
> some of its own fields illegitimate? Is there another way to tackle this
> problem? Any help would be greatly appreciated.
>
> Peter Binkley
> peter.binkley@ualberta.ca

hth
beate

-- 
����

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org