A lot of guys ask me the question "is it okay for me to buy her a drink?" It's actually a controversial subject among guys who teach others how to meet women. Some people will say "never," because it makes you look supplicant, or needy, while others say you should always do it.
Personally, I don't think it's a big deal.
You certainly don't want to give the impression that you are bribing a woman into talking to you. That's why I generally advise that you don't open a conversation with "can I buy you a drink?" However, at a certain place in an interaction, it's totally appropriate to do this.
Usually, when I buy a woman a drink, it's 5-10 minutes into the conversation. At this point, we're moving past small talk and silly jokes and entering the "getting to know you" kind of conversation. When she says something funny, or interesting, trying to impress you a bit, that is the time to buy a drink for a woman. By waiting until the right moment, you make her feel as though she has earned your interest (buying a drink shows interest, obviously) by impressing you.
I also don't just say "what do you want?" and walk off. Buying a drink is a good opportunity to go for a little walk around the bar, and perhaps speak to her in a more private situation. If she's surrounded by friends (and most beautiful women are), a walk to the bar is the easiest and most natural way to get her away from them so you can speak with her one-on-one. Getting a woman one-on-one is a very important step in building the kind of deep attraction that you need in order to meet up with her again.
One disclaimer though - if she's already drunk, don't buy her another drink. Not only is it morally wrong to ply women with alcohol, but it's much more likely to ruin your interaction with a woman than make it better. There's nothing worse than meeting a really sweet woman at 10PM, only to find out at 1AM she's a rambling, annoying drunk. Sober women are more fun, more interesting and much more likely to answer the phone when you call (or come home with you, for that matter).