You obtain your Visa in to Turkey at the airport when you arrive. The cost is different depending on where you are from.
Australia has been heavily penalised for some reason, the cost has recently (15May2012) increased from USD20 to USD60 (EUR45). USA is still USD20and New Zealand is free!
Only USD and EUR are accepted.