As France is currently the only country where Apple allows the iPhone to be sold without a contract and unlocked, I thought I would share my experience since purchasing an iPhone in November of last year.
Living in France and deciding I needed the unlimited data option, I opted to buy the iPhone with a contract, and then unlock it right away as I do travel on business to the UK quite often. First and foremost, Orange offer a 12 and 24 month contract - albeit for a few Euros more for 12 months (which is what I ended up going for). Incidentally, Orange recently introduced a business option for the iPhone which comes in at 339 and 29.90 per month for 24 months. The cost to unlock the iPhone came in at 100 as advertised.
The unlocking process involved a call to Orange customer services followed by a confirmation letter within 5 days. To summarise, Orange send the IMEI number of my iPhone to Apple which I assume is stored so that when my iPhone syncs with iTunes, it knows to "unlock"