Re: textarea
| From: | Robert Cummings | Date: | Sun, 13 Apr 2003 11:00:43 +0000 |
| Subject: | Re: textarea | ||
| References: | 1 2 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-143658@lists.php.net to get a copy of this message | ||
Indeed this is a PHP question. The question is how to propogate the
value of a textarea in one form into the textarea of another form
in the next sequential page via a PHP variable. The answer to his
question lies in retrieving the value for the first textarea via
the PHP $GLOBALS['HTTP_POST_VARS'] array such that in the first
page he has something like follows:
<? $descrip1 = 'Default text!'; ?>
<textarea name=descrip1 rows=5 cols=60
value="<? echo $descrip1 ?>"></textarea>
And in the second form he will have something like:
<? $descrip1 = $GLOBALS['HTTP_POST_VARS']; ?>
<textarea name=descrip1 rows=5 cols=60
value="<? echo $descrip1 ?>"></textarea>
Hope that helps,
Rob.
Ps. After writing the above a realized you don't need to assign the
POST value to $descrip1 if you are using register globals (which I
haven't used in months :).
Leif K-Brooks wrote:
>
> 1. This has nothing to do with PHP!
> 2. This has nothing to do with PHP!
> 3. You can find out within the first few results of a google search that
> the value goes between the <textarea> and </textarea> tags, not in an
> attribute.
>
> Diksha Neel wrote:
>
> > dear mr. wong,
> >
> > went through the information provided by the
> > links you gave me.
> > but it did not clear my doubt.
> > i'm sorry for troubling you but
> > what i want to ask is the following:
> >
> > in a form in a PHP page i have the following:
> >
> > <textarea name=descrip1 rows=5 cols=60
> > name=\"descrip1\"></textarea>
> >
> > the first form is posted to the next which tries to
> > retrieve the value of the above textarea as follows:
> >
> > <textarea name=descrip1 rows=5 cols=60
> > value=\"$descrip1\"></textarea>
> >
> > but i am not getting the value of textarea of the first form
> > retrieved in the second.
> >
> > thanks,
> > diksha.
--
.---------------------------------------------.
| Worlds of Carnage - http://www.wocmud.org |
:---------------------------------------------:
| Come visit a world of myth and legend where |
| fantastical creatures come to life and the |
| stuff of nightmares grasp for your soul. |
`---------------------------------------------'