kadin
asked on
form, textarea. how to wrap text (address) for input into database?
My form textarea has wrap="hard". I input into database and then retrieve and echo it page. It dose not wrap. I changed table field type from varchar to text, but still it echo's back as one long string. This is a postal address. How do I go about doing this? Thanks.
Instead of using textarea, should the input be 3 or 4 fields.? Name, street, city, state, zip etc.
Instead of using textarea, should the input be 3 or 4 fields.? Name, street, city, state, zip etc.
Are you doing anything with the content before you put it in the db or before you put it back in the textarea?
ASKER
no.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Thanks so much. That worked.
ASKER
When you say.
It also helps with normalizing your database and not having unnecessary large fields.
Do you mean it is better to break up the address name, street, city etc. to store into database?
I will be copying the postal address from an email and inputting it myself into a form to store in database. Then print it to a webpage.
It also helps with normalizing your database and not having unnecessary large fields.
Do you mean it is better to break up the address name, street, city etc. to store into database?
I will be copying the postal address from an email and inputting it myself into a form to store in database. Then print it to a webpage.
Whichever works the best and easiest for you. If all you are doing is storing the address with no intention of doing anything else with the data then keep on storing it in one field.
ASKER
Thanks again.