A man accused of assaulting his girlfriend and her mother failed in his bid to keep his personal details out of the Examiner.
Aiken Crowther claimed he was fearful of attacks against him if his address was made public.
His solicitor, Ismael Uddin, asked for a Section 11 order under the Contempt of Court Act.
This allows a court to ban the media from reporting a person’s name, address or other information.
Mr Uddin told Kirklees Magistrates’ Court: “There’s been verbal innuendo towards him in the street and he’s concerned that this matter is reported widely - there seems to be a vigilante mentality in the Wakefield and Huddersfield areas.”
But prosecutor Charles MacRae argued that the 23-year-old’s hearing was taking place in open court with the Press usually able to freely report hearings.
He said that this principle of open justice would only be prevented in exceptional circumstances and Crowther had not shown that he was at serious risk of harm from others as no police reports had been filed.
Deputy District Judge Michael Hopkinson said: “Unless there is a direct threat that can be shown to interfere with the administration of justice I’m not minded to ban any publicity.”
Crowther, of Albert Street in Cleckheaton, pleaded not guilty to two charges of assault by beating.
The alleged offences took place at his home on May 25 and involved his girlfriend and her mum.
On that date a row broke out between Crowther and his girlfriend over how some cocaine came to be in the property, Mr MacRae said.
He is alleged to have assaulted his girlfriend who then called her mother.
When she attended she was also hurt by Crowther as he snatched the phone from her as she tried to dial 999, Mr McRae said.
Crowther was told that his trial will take place at the Huddersfield court on September 20.
Judge Hopkinson directed that both complainants can give their evidence from behind screens during the hearing.
In the meantime Crowther has bail conditions not to contact either of them or go to an address in Skelmanthorpe.