Is it safe to use the 12W iPad 4th gen power adapter for earlier iPads and iPhones?
Yes. The wattage ratings are maximum and all iOS devices will only pull the current they need to charge. 

Should a device or an adapter get too hot to operate safely, they will shut off.