Is an unlocked phone and a jailbroken phone the same thing? I just read that apple is now selling unlocked phones? I also read somewhere earlier (probably Wikipedia) that jailbreaking was made legal.

Is jailbreaking and unlocking the same in this context?

Addendum:  If they are different, does it also mean that jailbreaking doesn’t unlock the phone? and the steps to unlock are different? I was under the impression that when I jailbroke my phone (using redsn0w), it also became unlocked.
No, they're not the same thing.

Jailbreaking is a process where the iOS software and device firmware that Apple ships is modified to allow unauthorized/unsigned code to run. 

Unlocking means that you can use a GSM iPhone with any GSM carrier, not locked to one carrier in exchange for a discount or an exclusive sales agreement.

Jailbreaking is the first step needed to unlock a phone. Jailbreaking allows additional root access to the device and allows for other app store mechanisms to load apps and code onto the phone.

Some utilities, like redsn0w, will automatically unlock certain models of iPhone in addition to jailbreaking. 

Apple has sold authorized unlocked phones in several markets worldwide.
As of June 2011, Apple will sell unlocked GSM phones in addition to the locked to Verizon and AT&amp;T models. Some carriers will unlock an iPhone once your contract is up. There is a lot of confusion in the US on this point due to conflicting law of software licenses and Library of Congress exemptions that permit users to modify their phones for the express purpose of unlocking them when not bound by a contract to one carrier.