[Zope] Zope and html forms problem
Jim Sanford
jsanford@atinucleus.com
Wed, 9 Feb 2000 15:49:57 -0600
You are using the textarea tag incorrectly
<input textarea name="pass_answer" value="<dtml-var answer>" rows="5"
cols="50" wrap ="soft"> </textarea>
should be
<input textarea name="pass_answer" rows="5"cols="50" wrap ="soft">
<dtml-var answer>
</textarea>
The value for a textarea goes between the tags, not in the beginning tag.
__________________________________________________________________
Jim Sanford
. Database Engineer
/ \ / Accelerated Technology, Inc.
/ / 720 Oak Circle Drive East
/ / \ Mobile, AL 36609
/ / \ Voice: 334-661-5770 fax: 334-661-5788
/ \ E-Mail: jsanford@atinucleus.com
Web: http://www.atinucleus.com
Source Code, No Royalties, Any CPU...It just make sense !
__________________________________________________________________
----- Original Message -----
From: TMGB <bennettt@am.appstate.edu>
To: <Zope@zope.org>
Sent: Wednesday, February 09, 2000 3:03 PM
Subject: [Zope] Zope and html forms problem
My Zope configuration is (from the Control Panel):
Zope version: Zope 2.0.0 (binary release, python 1.5.2, win32-x86)
Python version: 1.5.2 (#0, Jul 30 1999, 09:52:18) [MSC 32 bit
(Intel)]
System Platform: win32
Process ID:(deleted)
Running for: 33 days 23 hours 25 min 40 sec
I have a page that is created when a user selects his/her name from a
drop down select option menu. When the submit button is pressed Zope
retrieves fields from a MySQL database and for all records that this
user is the responder and has not processed.
Now, on the page that is rendered the user may select one record (that
has a question) to reply to. Pressing the button for that record, a
Zsql method retrieves the necessary fields needed to respond to this
question. The form below displays the question and the answer, I also
keep the record number (ID) to finish the processing. If I put the word
input in front of the line that has <dtml-var answer> as shown below, I
lose my columns and rows and get just one row. If I remove the word
input from the beginning of that tag I get my columns and rows as
defined but no text in the window on the html page although the html
source still shows the text for <dtml-var answer>. I need the text to
be in that box in case someone wants to append to the original answer.
If the text does not show, it over writes the data in the answer field
of the database. On the other hand when one row shows I can scroll to
the end and append to that answer and it overwrites data in the answer
field of the database but It includes the original text so, ultimately I
have appended to the answer.
Originally, the form method just put the answer in the answer field of
the database and the send mail was done separately, now I'm trying to
have it set the reply in the answer field and send the email but there
are some send mail problems doing them together and I'll submit that in
a separate request for help.
html stuff up here
<!--#in get_one_rec_by_id size=50 start=query_start-->
<H5>This reply will be added to the database of all questions asked for
<H3><I><font color="#FF0000">recipient
<dtml-var submitter null="">.</font></I></H3> After pressing the
submit button, you will see a conformation
page that confirms that your message has been added to the
database. If you want this question added to
the frequently asked questions use the page where you view all of
the questions you have not finished.
</H5>
<BR>
Question:<dtml-var question null="">
<br>
<TABLE><TR><TD>
<form action="send_mail" method="get">
<input type="hidden" name="pass_id" value=<dtml-var ID null="">
size="6">
<input textarea name="pass_answer" value="<dtml-var answer>" rows="5"
cols="50" wrap ="soft"> </textarea>
<input type="submit" value="Set Answer">
</form>
</TD></TR></TABLE>
Is there a way I can have both a textarea or some other object to show
the complete text of the answer field from the database.
--
TIA,
Thomas
--------------------------------------------------------------------
Rock and Rule
Zope Rocks -- http://www.zope.org
Python Rules -- http://www.python.org
--------------------------------------------------------------------
Thomas McMillan Grant Bennett Appalachian State University
Computer Consultant II University Library
bennettt@am.appstate.edu
http://www.library.appstate.edu/webmaster/
Voice: 828 262 6587 FAX: 828 262 3001
Windows 95 is a 32-bit extension to a 16-bit patch for an 8-bit
operating system that was originally coded for a 4-bit microprocessor.
- Chris Dunphy Boot Magazine
_______________________________________________
Zope maillist - Zope@zope.org
http://lists.zope.org/mailman/listinfo/zope
** No cross posts or HTML encoding! **
(Related lists -
http://lists.zope.org/mailman/listinfo/zope-announce
http://lists.zope.org/mailman/listinfo/zope-dev )