well, first of all - you don't want to risk him injuring himself one of these times when he gets out of the bed, so yes.. find an inexpensive toddler bed that will use the toddler mattress - or put the mattress on the floor until you can get the toddler bed frame (one of my daughters did this at about 18 months! and the second time she did it in one night I just took the mattress out and put it on the floor - then got out the old toddler bed frame later.
and he will probably get up several times, too.. but at least he wont' risk injuring himself. You will have to come up with a strategy for training him to stay in bed.
The first place to start is to stick to a routine for getting ready for bed. Do the same things in the same order every single night at the same time - or as close as you can get to it every night to establish that he is getting ready for bed. You may want to add to his routine things like lavender scented baby bath and lotion, we also used aromatherapy oil on our son's feet, he liked the gentle massage, offer him chamomile tea or warm milk and a protein snack (some cheese, turkey slices, peanut butter on crackers), soothing music or a "white noise" in the room (a humidifier, fan or one of those waterfall things), reading books (no rowdy ones), prayers or whatever else that is calming before bedtime and tell him "we are getting ready for bed" and let him know what you are going to do next i.e. "after your snack we are going to brush your teeth" so he knows.
once you have him in bed, you might need to stay with him for a while until he falls asleep, and you may only need to do this for a few nights in a row until he gets the idea. If he gets up, you firmly say "no, you have to go to stay in bed" and put him back. If he cries, be tough - and go back in 5 minutes, then 10 minutes, then 15 minutes - if he is crying this whole time, he ought to cry himself to sleep by about the time you are going to wait 15 minutes to go back in there.. if he stays in bed and cries.. If he keeps getting up, you may need say "you can read look at a few books in bed if you like, but you cannot get up. Or even offer him a soft cuddly toy he could sleep with.
These strategies worked pretty well with my one (out of five) that gave us this very same problem at this young of an age.
best wishes.