Christopher Lees, who put an intimate picture of his ex-girlfriend on Facebook.
A yob who filmed a cat being thrown from a tower block put a photo of a nurse performing a sex act on Facebook - and threatened to send it to her parents.
Christopher Lees tormented his ex-girlfriend after they broke up and she fell pregnant by another man.
He created a fake Facebook profile containing the image and added a message saying he would send it to her mum and dad.
The animal had to be destroyed.
The 27-year-old, of Wilsford Close, Druids Heath, admitted a charge of harassment a tBirmingham Magistrates’ Court in connection with the Facebook image of his ex.
Deputy District Judge Miller said: “The harassment included putting on Facebook a photo of her performing a sex act.
“The reason why this is serious is that it is grossly insulting and damaging to the victim.
“I have to think about the gravity of the offence and deterrence of others.
“Everybody must know if they do this they will almost certainly risk losing their liberty.”
But the judge accepted the image had been taken down after a couple of hours and it was unlikely it had been seen by anybody else apart from Lees and the victim.
Lees was sentenced to four months, suspended for a year, ordered to do 150 hours unpaid work, pay £500 compensation and £105 costs.
The judge also made an indefinite restraining order banning the Lees from contacting the victim.
David Palmer, prosecuting, said the defendant had been in a five-year relationship with the nurse.
He set up the face Facebook account in February.
Christopher Stewart, defending, said: “He admitted the offence straight away and was emotional and broke down in tears.
“He lives with his parents and works full time and otherwise lives a law-abiding life.
“The catalyst for this, although there clearly was a messy break up, was that he discovered his ex-partner was pregnant with her new boyfriend.”
Mr Stewart said there had been other “family issues” and he would lose his job if he was found guilty.