During the time of Prophet Yahya (a.s), there lived a king by the name of Hirodis, who was fond of him (a.s) and considered the Prophet to be a just and righteous person.
There was an adulteress with whom this king had been having an illicit relationship; as she became old, she began to ornament her daughter and present her before the king, who eventually fell in love with her and desired to marry her.
He questioned Prophet Yahya (a.s) about the issue who, on the basis of the religion of Prophet Isa (a.s), declared it to be unlawful. Consequently the adulteress harboured resentment and malice towards Prophet Yahya (a.s). One day, observing the king to be in a state of intoxication, she adorned her daughter and sent her before him. Seeing her, the king sought to gratify himself but the daughter said: “I shall submit myself to you only upon the condition that you sever Yahya’s head from his body.” The king, in his state of inebriation, agreed and upon his instance, Prophet Yahya (a.s) was beheaded.
According to another tradition, the king desired to enter into marriage with his niece, by the name of Hirodiya, but Prophet Yahya (a.s) prohibited such a marriage as a result of which the lady coveted the Prophet’s death.
Imam Baqir (a.s) said: “Yahya’s (a.s) killer was an illegitimate child, as were the killers of ‘Ali and Husain Ibn ‘Ali (a.s)).”
When Prophet Yahya (a.s) was murdered Allah made Nebuchadnezzar (or Kardus), one of the Babylonian kings, dominant over Bait al-Maqdas, who initiated a massacre in the city. It was only when he had killed seventy thousand of the inhabitants of the city that Prophet Yahya’s blood stopped bubbling and calmed down .( Tarikh-e-Anbiya, vol. 2, pg. 284 )