Here's just one site with some basic information on container
gardening. Googling that phrase will get you more.
Use the largest containers you can, preferably plastic or
wood. Small ones dry out too fast and the
roots can get too hot. Those plastic party tubs designed to hold ice and sodas are pretty good for shallower-rooted crops like lettuces. Be sure to drill or burn drainage holes in the bottom. (Small soldering irons -- $7 at Harbor Freight, etc -- are wonderful for making holes in plastic.)
One great way to water in a container is with an unglazed terra cotta pot that has had its hole plugged with hot glue: Fill a large container (half a barrel or so) with your planting mix, and bury a large (one gallon or so) clay pot almost up to the rim (leave 3/4") and set a saucer in the top after filling with water (so lizards and
bees can't drown). Also water the soil thoroughly, then plant your plants or seeds. Keep the clay pot full of water. If the soil needs water, it will ooze through the pores of the pot. If it doesn't need water, the water will stay in the pot.
If you are putting your containers on a roof or balcony, it might be a good idea to use lightweight synthetic potting soil with some
compost added, as it is lighter than regular soil.
I've heard that even corn can be grown in large containers, but you'll have to plant several in one container, as they are wind-pollinated and must be near each other.
Sue