The first step towards ensuring payment is making a contract. The contract should outline payment terms, including how out-of-pocket expenses will be managed. You should also:
Research the client before signing
Ask for a deposit to cover your costs
Ask for mid-project payments
Use professional invoices
Make it simple for them to pay you (online, by credit card)
Keep meticulous expense records
Avoid Net 30 or 60 payment due dates
Include a late, rush and cancellation fee in the contract terms
If they provide their own contract, have your lawyer review the terms if it is a high-priced contract. They may also require that you carry your own liability insurance. You may also be asked to sign a Confidentiality Agreement.