Re: Arrays and Textareas
| From: | Weston Houghton | Date: | Wed, 13 Sep 2000 22:06:00 +0000 |
| Subject: | Re: Arrays and Textareas | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-16651@lists.php.net to get a copy of this message | ||
I had originally planned to keep all of the data in a database, but after
looking at it and seeing that it would be dynamic, I wasn't quite sure how
to layout the database schema, and decided to write the resulting data to a
file, as that meant I could just use it as an include in the needed file.
I've tried urlencoding the serialized version of the textarea, and putting
that into a hidden field, and it seems that might work, but it sure as heck
seems awkward. I'm definitely open for a good lead on this one.
Wes
> Weston,
>
> You can use hidden fields for text fields, too, but they could become big,
> unweildy and you'll have to escape some HTML characters (" comes to
> mind) to get it to send correctly.
>
> Alternatively, if the ultimate goal is a database, you could insert it,
> retrieve the new ID (mysql_insert_id() I think is what it's called, but I
> can never remember) and pass the ID. Then, you update based on that ID,
> instead of one big insert at the end.
>
> Maybe not the perfect way, but perhaps better than passing all that info
> in a hidden field?
>