During Robert Riley's sentencing, chairwoman of the bench Georgina Scannell voiced her disgust at his "vile" and "offensive" online messages.
The offensive messages outraged the public. You had complete disregard for the tragic death of Ann Maguire.
Besides this, countless other vile messages were made by you.
The bench finds these were racially and religiously aggravated.
The offences are so serious that only a period of immediate custody can be justified.
More top news
Stars of Team GB at this years' Olympics were in Wales today, as part of ITV's I Am Team GB campaign.
As Wales gets involved in the country's biggest sports day - Our Olympians have been getting in on the action.
ITV switched off all of its channels for an hour on Saturday as part of a national sports day event.