I use a playpen. For the potty training, I put wee wee pads in there with her. It has something in them that makes them naturally want to use them. After she got used to those, I'd start taking her outside and tell her 'go potty'. At night I still kept her in the playpen with the pads and if I left the house. My main reason for using a playpen is my Lola is very tiny. I felt she needed to be able to eat whenever she wanted to, so this way I could leave her food and water in the playpen with her. Now she's over 7 months old(about 2 1/2 pounds) and I only use the playpen if I'm leaving her home while I do some errands. Mostly because we have stairs and she can't figure out how to go down them, only up.
I no longer use the pads, she holds it while I'm gone and sleeps in bed with me now. She will occasionally have an accident if she has ended upstairs and I didn't notice fast enough.