Eliciting User's Location

I have added User Profiles to my website, and similar to SitePoint, when a User makes a post, the User’s Username, Online Status, Picture, and # of Posts appears to the left of their post.

I would like to add the User’s “Location” but am unsure the best way to get this from Users?!

1.) When a User creates a Profile, should I be bold and ask them…

  • City
  • State
  • Zip Code

…and hope they share?!

2.) When a User creates a Profile, should I back off an let User’s add what they want by asking for…

  • Location (text field)


I’d go with 2. If you asked me to give you my location for some random website, I’d probably leave right away.

The important thing is to make it completely optional. And also to mention the reason you are asking for it. If you do that, I can’t see any problem.

But, in any case, don’t ask them for “city, state, zip code”. I understand states and zip codes are something they have in the USA, but it won’t mean much to people in the rest of the world. Just ask for location and leave it to the individual to decide how much to give.


How should explain a reason?

They are creating a Member Account so they can leave a Comment, and they are asked for…

  • First Name
  • Username
  • Email
  • Password
  • Location

[INDENT]Where * is required.


I don’t understand the the big deal. It is easy to input bogus information that if someone doesn’t want to share they don’t have to. I do it all the time.

Fielding the information will make it easier to handle server-side. Otherwise, you will have to isolate it into separate pieces or merely insert the string into the DB as a text. However, inserting the string as text is going to make it painful to format the information in different ways and run statistics.

You’re losing me here, oddz?! It sounds like you are answering both ways?! :lol:

Here is what I want…

Ideally, people would give me an accurate City, State, Zip - let’s assume USA for simplicity.

Why do I want that?

For now, just so you can see…

<Debbie’s Picture>
Location: Phoenix, AZ
Posts: 119

I am willing to give people a Text Box where they could type…




Planet Earth

My Cube

…and so on.

Obviously it is better for me if I can get ACCURATE and DETAILED Location information since it would help me know who my Users are and help to cater things better to their needs.

Since I am collecting the “Location” as part of “Account Registration” but there is no e-commerce involved in this part I think I need to be more flexible in the format that I allow people to respond in.

Make sense?

Now, how does all of that relate to what you were saying oddz??



I don’t think I have ever seen a registration form which doesn’t field that information. The only places I can recall that use a single text field for a location are mapping services like google maps and mapquest. I think it play to your advantage to field the information for possible statistic, formatting and simplicity of saving it to the db server side. You may only want to display it as a single line now now but that is highly likely to change. The painful and uncertain process of crawling the db extracting address components of a user supplied string at a later reason is reason by itself to use fielded data. Fielded data is a good – thing. Otherwise, your essentially storing a something that represents a complex object in a single column which will come back and bit you later. Storing a full address as a single text field is really no more evil and serializing data and tossing it into a single column – same concept. I know I am talking a lot here about programming and the potential consequences of either decision but it really can’t be avoided. Taking into consideration only useability just can’t be done here.

Pick a side, oddz?! (:

I know I am talking a lot here about programming and the potential consequences of either decision but it really can’t be avoided. Taking into consideration only useability just can’t be done here.

I was just playing off of earlier advice from a lot of people on SitePoint that basically says, “You don’t have the right to ask people for their personal information, and if you did that to ME I’d be outta here in a heartbeat!!” (Such finicky people here sometimes?!) :rolleyes:

I would prefer that User’s enter City, State, Zip but figured if I just left a “free-form” Location field that it would allow people…

1.) Levels of what they reveal
2.) Room for creativity

The purpose today is just to give other Readers a sense of where a person is from. But, yes, down the road I might want specific and traditionally-formatted Location data.

So I think I hear you saying to have these fields in my Registration Form…


(See, that is another advantage of one Location field… It allows someone in another country to follow their format.)



Well, the reason could be as simple as “Some of our members might be interested in knowing your location” or “Knowing the location of our members helps us to decide what services to offer”.

If there really is no reason, then that might suggest that you shouldn’t be asking for the location in the first place. But I don’t really see a problem with this.


For what its worth, in the link below, USA Today lets people type free-form what their Location is…


For example…

Works at The Internet

Best Buy

Ohio University

Ruston High School


So does Sitepoint. =p

How come you want to know people’s location? Is it to get a better idea of your users demographics? or are you just interested?

I agree with Mike that as long as you are clear about why you want people info and you make it optional than hopefully you will get the information you need.