dekern@tallysystems.com (dekern) wrote in message news:<5f752fd4.0310281057.7eef1174@posting.google. com>...[color=blue]
> Martin Honnen <mahotrash@yahoo.de> wrote in message news:<3f9e8877$1@olaf.komtel.net>...[color=green]
> > dekern wrote:
> >[color=darkred]
> > > I have been trying to set the default text value of a TextArea element
> > > for about a day now without any luck.
> > >
> > > Similar to the code used to set the Text field below I would like to
> > > use the returned (for lack of a better term) value in a TextArea
> > > element ie. {TITLE}.
> > > this works:
> > > <input readonly="true" value="{TITLE}" name="titleedit"
> > > size="50"
> > > maxlength="255" class="detaileditentry">
> > >
> > > But of course there is no "value" attribute for a TextArea element.
> > > I've tried embedding a "value" between the
> > > <textarea...>{DESCRIPTION}</textarea> but that gives me the string
> > > literal.
> > >
> > > I've tried using JavaScript to set the
> > > document.input.descriptionedit.value value but this has to be done at
> > > the "onload" point and of course the {DESCRIPTION} has no value at
> > > that point until a LOAD_REQUEST is made (after the onload call).
> > >
> > > Again, this is something I want to set at load time and therefore
> > > can't use the "onclick" or similar event to set this value.
> > >
> > > Does anyone know a trick to setting this type of element in this
> > > manner?[/color]
> >
> > Your subject line talking about a "ResultSet" and the syntax
> > value="{TITLE}"
> > suggest you are using some data binding feature that is not part of
> > HTML. Maybe you can elaborate where that ResultSet comes from and
> > where/how you expect the TITLE replacement to happen, on the server or
> > on the client.[/color]
>
> I use JDBC ODBC to retrieve record sets from a database. I then
> "push" the data into an XSL file for display purposes. Inside the XSL
> I have a template defined that displays the returned record
> information. Often this information is static and displayed in a
> TABLE.
>
> In cases where I am simply trying to display data I use syntax like
> such:
>
> <xsl:for-each select="/Report/DeviceList/Device">
> <xsl:if test="SYSTEMDESCRIPTION">
> <TD class="datadata">
> <SPAN>
> <xsl:value-of select="SYSTEMDESCRIPTION"/>
> </SPAN>
> </TD>
> </xsl:if>
> </xsl:for-each>
>
> where SYSTEMDESCRIPTION is a column returned in the ResultSet of the
> database query.
>
> What is different here is that I am trying to access the value of the
> DESCRIPTION column of a returned record and seed it into the TextArea
> element so a user can modify the text.
>
> As you can tell my HTML/XSL is very weak and perhaps I have posted to
> the wrong group - if so, sorry and could someone point me to a group
> that could possibly answer my question
>
> Dave[/color]
I figured it out - the above code does work in the
<textarea><xsl:value-of select="SYSTEMDESCRIPTION"/></textarea>
format, as long as you spell the tag correctly!
Thanks for any and all posts.
Dave Kern