Information like this shouldn't be banned...It isn't going to work. A better approach would be to ignore or scorn those who would post such personal information about something that is purely a painful family issue.
I don't think your definition of "work" and the judge's definition are the same. No one expects that this info won't be made public on the internet. By issuing a gag order, however, the judge provides legal leverage to prosecute or legally disadvantage dickheads who are harassing this family. What we have evidence you got your religious friends across the pond to post this info in defiance of UK law? Guess who's church is now classified as a criminal group collaborating with foreign religious extremists to undermine the lawful authority of the commonwealth?
Mind you, I don't particularly support the legal system to undermining the basic right of free expression, but at the same time if these people are claiming the legal protection of the law for themselves, they have to acknowledge that just because a law is not practically enforceable does not mean they won't be punished for breaking the law or encouraging those beyond its reach to do so. And in the end that may be enough to at least quash some of these religious nutjobs and keep them from harming innocent people in their attempt to force their own religious beliefs on others.