When you’re asking a user for their address, do you tend to go with 1 field for the whole thing or separate fields (Address, City, State, Zip Code, Country)? It seems to me the latter is how it’s usually done, and those fields could be concatenated into 1 extra field in the database for ease of use.
Anyway, just wondering if there’s a good reason to do it one way or the other?
I separate them out to help prevent users from inputting bad data. In one form, they can enter whatever and it’s hard to validate against. In multiple fields, you can run validation checks on each of them independently.
Makes sense, thanks @andrewgassen. I guess the one thing you don’t get when you do each field separately is the auto-completion.
E.g. if a user enters only the street/city/state, an ‘address’ field will autocomplete the zip code. And even if just the street and city are entered, auto-complete often gets both the state and zip right.
This topic was automatically closed after 70 days. New replies are no longer allowed.