school are in a difficult situation if your ex has told them under no circumstances must there be photographs of your child. They are not obliged to ask for documents to check whether there is a court order.
A letter to the Chair of Governors as WYSpecial suggests explaining that there is no court order may resolve things without recourse to lawyers.
Please don't think I'm unsympathetic. I can fully understand your frustration. Clearly communication has completely broken down between the two of you and that is very sad when you are trying to remain in your son's life. Send a polite letter explaining the situation and see what comes back.