Mainly there are 4 companies which are operating the domestic flights starting between Lima as well as Cuzco. These are Lanperu, Aero Condor, Star Peru and TACA. You may consider the tour operators to avail great and cheap services. The Inka Trail Tour on a Budgets are easily available.
I usually prefer to travel through buses. There are mainly 2 companies those who are offering the bus journeys such as Cruz del Sur as well as Ormeno. With the Cruz del Sur you may easily buy the tickets online. However, Ormeno also has the website as well, but only in Spanish.
In Cusco you might also have to always stay for a single night, since train to the Machu Picchu would start quite early in morning and then they will come again from Machu Picchu at the evening. I was lucky enough to avail the Salkantay Trek Cheap which made my journey to be interesting as well as thrilling. You may also check different websites which are available for the hotel. You may also Stay around the Plaza de Armas that is at center of city. You may also purchase the train tickets for one day prior to the departure. You may also get the assistance on the tickets from the hotel desk as well.
You can also check train schedule at Lan Peru in the website, and pick the journey. Peru rail offers three train services to Machu Picchu.