Respecfully, that's not fair and it's also not good advice. As a full time piano teacher for almost twenty years, I get oodles of students from referrals. That's great, and I'm flattered and happy to be gainfully employed.
But, I've always had a three line ad in the yellow pages since the day I decided to go full time. The part of your post I take exception to is the comment that one can't necessarily trust the person who placed the ad. So? What's that statement worth? Life is full of advertisements and the people that place them. Nothing is guaranteed - not even a good referral.
While I personally get many students from word of mouth, my teaching career would be half-complete were it not for the same plethora of students and families I've met who have responded to my yellow page ads. Simply, not everybody knows a neighbor (or has a neighbor, for that matter) or friend that has a piano teacher. Plus, one parent or student's needs may be different from another.
There are a hundred good and valid reasons to advertise and respond to an ad in the yellow pages pertaining to piano lessons. It's up to the individual to then decide if the person is a good fit. Just because my neighbor loves a certain piano teacher doesn't mean it's a good fit for another student. The ad is so the teacher can present his/her wares to the unknowing public. Another way to think of it is that many many kids and parents who easily found me in the yellow pages may have never had the great experience they eventually had when they finally found me...had they never opened up a phone book.
I just think you are doing potential students/parents a dis-service by dissuading them from reading and/or responding to yellow page ads. It's up to the caller to 'qualify' the teacher, no matter how the teacher is procured, and even then...it's a matter of personal preference much of the time.