They don't have to be vented outside but it's much better for the dryer to be vented outside then it is for the clothes dryer to be vented inside.
They do make an indoor vent box that allows you to vent your dryer inside but I find it doesn't work as good and I prefer to have my clothes dryer vented outside instead.