David,

The HTML code snippet is:

<textarea rows="10" name="body" cols="60" style="text-align: Left"
tabindex="5" $user_body> </textarea></b>

I'm not using CGI.pm to generate the HTML, I'm just doing a print statement.
The above snippet is within the <Form> section, of course. In fact, just
above this bit of code I print out $user_body in a table cell and it works.
However, this still doesn't let me get at the text to edit the sucker it
just does a "Hello World" sort of function for me.

If generating this via CGI.pm will let me do a <TextArea> and include the
variable I want...tell me more!

Thanks for your continued interest and help, BTW.


John--
[EMAIL PROTECTED]

-----Original Message-----
From: Kuchler, David [mailto:[EMAIL PROTECTED]]
Sent: Friday, July 20, 2001 5:33 PM
To: 'Notabene'; Perl Beginners
Subject: RE: Repost Form data for user validation / change -- how?


That's odd.  Are you using cgi.pm to generate your HTML or are you doing it
with a series of print statements?  I just tried it and it works fine for
me.  If you post at least the relevant code snippet, maybe I can see where
my explanation went awry.



David T. Kuchler
Technical Configurator
Pioneer Standard Electronics
[EMAIL PROTECTED]


-----Original Message-----
From: Notabene [mailto:[EMAIL PROTECTED]]
Sent: Friday, July 20, 2001 5:25 PM
To: Kuchler, David; 'Notabene'; Perl Beginners
Subject: RE: Repost Form data for user validation / change -- how?


David,

I just tried your suggestion and <TextArea> won't accept the imbedded
$the_text_you_want. It ignores it. (Moving the entire site to another
application won't work at this juncture...too much has already been
invested -- I can't have the tail wag the dog at this point <g>).

Beyond using this tag, there must be some standard way one can
programmatically communicate back to the user via web page... I just want to
repost the e-mail body text and allow the user to edit it and re-submit the
thing. How?

Thanks, again.

-----Original Message-----
From: Kuchler, David [mailto:[EMAIL PROTECTED]]
Sent: Friday, July 20, 2001 4:59 PM
To: 'Notabene'; Perl Beginners
Subject: RE: Repost Form data for user validation / change -- how?


To auto-fill a textarea with default text, it's different from text boxes.
For input boxes, you can do value=$the_value.  However, for textareas,
you'll need to put out something that looks like this:

<textarea>$the_text_you_want</textarea>

So you're doing it as the content of the tags, not an attribute of the tags.

Now, as far as talking to Frontpage forms, I agree with the sentiment
expressed by Guilherme Pinto:  "Change to Dreamweaver ;o)"  I understand
this isn't always an option, but if you can, I strongly recommend
Dreamweaver.

Dave K.


David T. Kuchler
Technical Configurator
Pioneer Standard Electronics
[EMAIL PROTECTED]



-----Original Message-----
From: Notabene [mailto:[EMAIL PROTECTED]]
Sent: Friday, July 20, 2001 4:51 PM
To: Perl Beginners
Subject: Repost Form data for user validation / change -- how?


(I orginally posted this in CGI Beginners, but received no response. Perhaps
it more rightly belongs here, in the Land of Perl gurus?)

I would appreciate some help or pointers for the following CGI / Perl /
MS-FrontPage 2000 form validation problem:

I am writing an autoresponder which generates two e-mails: one to me, and a
confirmation back to the sender. I have a form on an MS-FrontPage web page
which collects initial user input. I want to send the input via CGI to a
Perl script for validation. If the data are NG, cycle it back to the user
who will be allowed to edit and resubmit it; if the data are OK, send it off
for processing.

The data are fairly simple: name, user's e-mail address, topic area, subject
line, and message body.

Being a newbie, I've stepped into this fairly carefully, teaching myself
Perl and CGI step by step, gradually adding functionality to the script so
that now the form sends the data to the Perl script, the script generates
the required two e-mails, and the e-mails are sent off as intended. My test
setup works well, and so far, I'm a happy camper.

Now, I'm adding the validation portion of the process -- I've been a
programmer for far too long to know that I never trust user input until
checked. I've created an imperfect copy of my web page which I use to echo
back to the user the original values if the data fails validation. I'll
cycle this until I'm happy with what they've submitted before allowing their
e-mail to proceed or give up on 'em and post a really rude message to their
browser (suggestions in that area are appreciated, BTW <g>).

I've discovered how to echo back to the user their entered 'name', 'e-mail
address', 'topic area', and 'subject' data. What I have trouble with is the
'message body' data. I'm using a <TextArea> HTML tag in the form and it
doesn't seem to be happy accepting variables as does the <Input> tag, of
course. I can't do a value="$message_body", for example, within the
<TextArea> tag. (Or, if I *can*, it doesn't seem to work for me...harumph!)

So, my first question is: how do I display, or echo back, the user's e-mail
message body so that they have the opportunity to edit it before sending it,
in this context?

Secondly, does anyone know of the 'proper' way to have a CGI / Perl lashup
talk back to a FrontPage form to allow for Perl-based, extensive data
validation (as opposed to the anemic 'validation' abilities that FrontPage
forms have)?

Thirdly, and slightly off-topic for this list, -- remember my "...imperfect
copy of my web page" -- how do I include FrontPage's background themes and
navigation features for my copy of the form page. I'd like the validation
'response' page to look just like the original calling page and to have the
user return to a calling page on the site, if possible.

And finally, am I actually headed in the right direction with all of this?
Yup, I know, "TMTOWTDI" -- that's what makes it fun, of course, but I'm in
the learning stage, so I need to know at least one or two decent ways to do
it, first, before I try variations on a theme.

I'm looking for methods, procedures, code samples, snippets, or whatever, to
guide me through this process -- simple English-based explanations wouldn't
hurt, either. <g>

Thank you, all.


John--
[EMAIL PROTECTED]


--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to