Well I cant give you a 100% answer on Squalor but Ill try my best.

Making buildings that increase the efficiency of how your city is run is the #1 way of combating squalor. These are buildings like Academy, all the Palace buildings, etc. Building buildings that increase happiness and health dont reduce squalor, only offset it.

Squalor is usually a direct result of overcrowding and poorly run cities so the most simplist method is to recruit armies from your biggest cities, not your closest cities to the frontline.

Using a strict population control system should help you keep squalor down. If you are still struggling just let the buggers revolt a few times and if you defeat them it reduces the population AND keeps them quiet :)