(1) Think like the monster. What would you do if your home was being invaded by a guy who could sit inside the walls? Dynamite is one answer....get them out! If they go up a rope trick, have a bright guy give a sneaky mook a
bag of holding or similar....extradimensional space inside an extradimensional space = random planar rift, ne?
Don't neglect Dispel and Greater Dispel. Your home is being invaded, man. No resource is too great to spend.
(2) Use the environment. Water-filled chasms, rooms with fire burning out the oxygen, traps that negate magic...all force the PC's to use resources.
(3) Keep it coming. Don't keep throwing monsters at them, but make it so they don't want to rest....perhaps one of their friends was captured, and they need to get to him quick, perhaps they've been hearing plaintive cries of "Heeeelp!" coming from down the dark and dangerous corridoor (great Blue Dragon lure). Maybe they're actively looking for an NPC who may be lost.
(4) Make the journey the goal. They're going to circumvent a passage way when it's just a stop on the road, but if, say, the passageway *contains* their goal (perhaps that is where the treasure is burried, or that is where they must look for the rune that will allow them through the staircase, or that is where the NPC that they need to save is kept).
(5) Dispel. Don't overuse it, but one or two uses will make the PC's aware that they can't lurk and jerk effectively. It suddenly makes them re-consider most of the options available to them. This also applies to counter-magic. For every divination power, there's an illusion that can decieve it. For every movement spell, there's a wall that can stop it. For every rest spell, there's a trap that can be put there over night. You can't afford to ignore the PC's magic anymore...it's their main asset, and yours, too.
In general, if it's just point-A to point-B movement, they're going to take the quickest route possible to point B. But if the point is the movement (they have to find something/get something/kill something along the way), then even though they can teleport, they don't really want to. And if they want to teleport, by this level, their enemies should be well enough aware of them and their capabilities to plan for that eventuality....let them teleport in over their heads, let them circumvent the trap (or think they have, thanks to
Mirage Arcana)...the real challenge isn't the journey or the trap, the real challenge is the critter at the end (a good +4 CR points above their level), or the dialogue with the hostage-holding BBEG, or the destruction of the NPC's magic item (and the NPC happens to be located somehwere in the deepest, darkest chasm of monsters in the dungeon)....it's not a direct motion, anymore. It's a problem to solve.