I don't find it especially difficult to outflank an enemy with missile troops. Maybe by themselves. When I advance my line, I usually use high defense heavy infantry (~7 units plus General) in the front to lock the bulk of their forces in combat. I keep four units of quicker melee troops just behind that main line (2 to each flank). When the heavy infantry are engaged, I quickly move these units outward to each flank of the enemy, without engaging, and using them to screen my missile troops (4-5) from any attracted enemy forces, which is usually cavalry if any. The missile troops (typically slingers or archers for the additional range, but javelins work too) are used to pelt the backs of their line's flank troops. If I feel like my missile troops are safe from attack, I'll send in my reserve fast melee troops to attack from the sides. It goes without saying you want to avoid using your missile troops on the same units the flanking melee troops are attacking. The remaining 3-4 spots I have in my army usually go to light cavalry with a decent charge. I usually keep them together, move them around the backside of the enemy while their line is occupied and attack their missile troops. When their missile troops are routing, I use them to charge straight into the rear center of their line. I haven't lost a battle using these tactics.
This method relies greatly on the ability of the heavy infantry to hold the line while you're outmaneuvering the enemy, so it's important to choose the highest defense unit you can. You also want to execute these maneuvers together in order to end the battle as quickly as possible. Not only will you save more of your men, but you'll also give the enemy much less of a chance of forming a response.
Here's a picture:
I wish I had made it a little wider, but you get the idea. I usually swing out a little wider than this shows.
Hope this helps.
Edit: I agree that missile troops are less efficient in town attack situations. I usually only use archers in these scenarios, and in a very limited capacity.