I don't think it's such a grand idea. It's been around for too long. Anyone doing a good search will very likely take a close look at your shoes as well.
I used to cache some money under the insole when travelling in some of the more dangerous places. I never got into serious trouble so the secret cache never really paid off either. But I did notice that whatever you store inside a shoe will get damaged if you walk a lot (I did). Paper money will degrade quickly. It's not just a matter of smelling like horse p**s after a while, it will get torn and possibly deteriorate to the point where not even a street vendor would accept it.
It's also a bad idea for other reasons. If you get mugged in a third world country the bad guys will frequently steal your shoes as well because they tend to be valuable. If you are arrested by the police or military your shoes may be removed (makes escape a lot more difficult - how well can you run barefoot?) or at the very least they will take away your shoe laces (and probably check if there's anything hidden under the insole).