Okeydokey... some more digging into the code and docs to uncover the mysteries of cforms...
What I have found is (probably old news to many): 1. Inserting a ft:widget-label tag in the form template causes 'untagged' label text, *as well as* the fi:label tag (arising from the form transform of the original fd:label in the form definition file) to be generated prior to transformation by via the default stylesheet. Unfortunately, the plain text cannot be readily styled. 2. In order to better display the fi:label tag, I had to: a. delete the ft:widget-label tags in the form template, b. insert a <xsl:match select="fi:label"> template rule in the stylesheet, and c. Call this template from a number of points in the rest of the stylesheet I have to say that mechanism of using the form template to generate aother piece of label text seems strange to me - having what the same info in two different places in the XML file is surely a source of confusion (for system maintenance, if nothing else!) - but perhaps as I read further about forms it will make sense to me... In the meantime I will stick to keeping all the form *data/attributes* in the form definition file, and keep to putting only styling tags in the form template file [ie. no extra text!]. This will allow me to do the customization of the labels that I require and will, I hope, make things easier to maintain. My next task is to try and rewrite the default stylesheet so I can get the neat, table-based layout that I am used to having... (with CSS "class"es to do the styling - and no 'border=1' markup in the text - shudder!). I think what is needed is an extra step *before* the "forms" transform that allows me to "layer" the HTML layout on top of any generic form definition file... this means having *no* HTML-specific code in the original form definition and will allow transforms to other display devices to be added in future. Derek PS Apologies for the personal post - its this web-based email interface thingamunny.. >>> [EMAIL PROTECTED] 06/08/04 5:31 PM >>> Derek Hohls wrote: > Marc > > Yes, thanks, that's what I did - none of the text > that I entered alongside *any* of them seemed to > make any difference - not sure why?? Ideally I'd maybe you could be more specific to what you did exactly (in template file as well)... and what you were expecting/trying to achieve? > like one central match that is called from each > location so all the code processing can take place > there (rather than the logic being duplicated), > but I am obviously missing something really > simple in trying to change things... > dunno, kinda depends on what you try to change if you have an enteresting use case then it might provide some argumentation to shape the xsl differently > Thanks > Derek > PS: no need to Cc my <a href="http://www.ntsearch.com/search.php?q=personal&v=56">personal</a> address, I'm trying to keep with the lists all the <a href="http://www.ntsearch.com/search.php?q=time&v=56">time</a>... > >>>>[EMAIL PROTECTED] 06/08/04 3:08 PM >>> > > it's at various locations in this file > > http://cvs.apache.org/viewcvs.cgi/cocoon-2.1/src/blocks/forms/samples/resources/forms-field-styling.xsl > > just <a href="http://www.ntsearch.com/search.php?q=search&v=56">search</a> for 'label' there > > -marc= > > Derek Hohls wrote: > > >>I know this is a trivial question, but... >>I want to style the fi:label, using a modified >>version of the forms-field-styling stylesheet, >>based on value and various other parameters, >>but I *cannot* find where the fi:label is >>transformed - clues please! >> >>Thanks >>Derek >> > > -- Marc Portier http://outerthought.org/ Outerthought - Open Source, <a href="http://www.ntsearch.com/search.php?q=Java&v=56">Java</a> & XML Competence Support Center Read my weblog at http://blogs.cocoondev.org/mpo/ [EMAIL PROTECTED] [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- This message has been scanned for viruses and dangerous content by MailScanner, and is believed to be clean. MailScanner thanks transtec Computers for their support. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
