The first one is not right. The nearest valid sentence might be "I could not do otherwise than laugh". "than laugh" describes the available option, as contrasted with the unavailability of anything else.
New words, one handy idiom, and a 2-minute quiz — delivered to your inbox to keep your streak alive.