Get the right mindset- First and foremost, you need to get mentally prepared to get a guitar and play. There are two aspects to this. First, you must recognize that learning to play music well is a lifelong endeavor, and it may take months to years in order to even begin making some nice sounds. You must have physical and mental endurance to push through failure and to learn. The second aspect of this mental preparation is more optimistic. Don't worry about being a guitar hero straight away. The professionals typically practiced hours a day for years before they set foot on stage. You don't have to be excellent to make good music, and you must recognize that you will get there if you keep trying.
Practice- Get ready for some grueling work. If you learn to practice, however, you will achieve results and be motivated to continue learning. There's nothing like playing one of your favorite songs to keep you going. Just make sure you are ready to set aside at least a little time every day for practice.
Get lessons- This can be the most critical aspect of learning the guitar. Lessons in combination with healthy practice can put you light years ahead of where you would be on your own. You may think the great players didn't take them, but do not be fooled. Every great player learned to play from someone else. To that end, seek out a teacher who can show you the ropes and help you correct mistakes early. It is worth the expense.
You can find lessons almost anywhere in person or on the Internet. A lot of online services for personal contact have sprung up. One excellent example is The Guitar Gym, http://guitargym.com.au/