Glen Fenton (20), of Condiere Terrace, Connor, was present at Ballymena Magistrates Court on Thursday.
As he waited in the public gallery for his case to come up, Fenton was told by the judge to stop texting on a mobile phone.
Fenton replied: “What mate?” to which the judge replied: “I’m not your mate” and ordered him to leave the public gallery and to take his friend with him too.
Fenton, who was wearing a Crusaders FC tracksuit top, later appeared in the dock, and pleaded guilty to resisting a police officer in the execution of his duty relating to an incident in March this year.
No details of the incident were given to the court.
Defence barrister Stephen Law said his client had a “very lengthy relevant record”.
The case was adjourned until June for preparation of a pre-sentence report.