Apple provides a pretty good explanation of how to upgrade: http://www.apple.com/osx/how-to-upgrade/
You won't be able to get to Lion or ML until you have Snow Leopard installed though. You can purchase SL from the Apple store for $19.99. Upgrade to SL, upgrade to the latest version of SL and then you can install Lion or ML.
The following post also provides a more detailed description of the process: https://discussions.apple.com/message/18215794#18215794