I am one who is not for circumcision without reason, and nobody, not even in San Francisco would be stupid enough to write a law denying circumcision if there were a medical reason for doing it.
That being said, no Court will uphold this. The problem with this kind of thing is that it would legislate denial of medical treatment as it is being quoted. If San Francisco were per se to pass this one some other group opposed to "organ transplants" could come in and ban organ transplants within the same jurisdictional boundaries. Though a law like this could sound as if it had a bias that some would perceive as "liberal" the ones most profiting from it could be "conservative extremists". First, the same law could be implemented at whim on any other cosmetic procedure that had similar guidelines. This law could also be twisted by extremists from either side. Approving this could also lead to a city ban on abortions. Then you could get a city ban on rhinoplasty, a city wide ban on face lifts because in San Francisco everybody should look as old or older than they are. Again the legal precedents are the problem on this one. If it passes, it will be a "free-for-all" with screw ball organizations trying to get one thing or another banned within their city limits.