Updated

Martin Bashir has resigned from MSNBC, nearly three weeks after delivering a scathing personal attack on Sarah Palin that brought him widespread condemnation.

The afternoon talk show host, a former co-anchor of "Nightline," says he decided to leave the network after meeting with MSNBC President Phil Griffin.

Bashir had already apologized for what he called "offensive" comments about the former Alaska governor, whom he also called an "idiot" and "dunce." He told viewers in a scripted commentary last month that someone should defecate in Palin's mouth. He was invoking an old slave punishment in response to a speech by Palin, a Fox News contributor, comparing the national debt to slavery.

Bashir took off two weeks for what was billed as a vacation, and criticism mounted as MSNBC took no disciplinary action against him, even as it booted Alec Baldwin over an alleged anti-gay slur hurled at a photographer. In retrospect, it's clear that by failing to suspend Bashir, MSNBC allowed public pressure to build to the point where the only way to control the damage was to sever its relationship with the British journalist.

In a statement, first reported by Mediaite, Bashir said:

"After making an on-air apology, I asked for permission to take some additional time out around the Thanksgiving holiday.

"Upon further reflection, and after meeting with the president of MSNBC, I have tendered my resignation. It is my sincere hope that all of my colleagues, at this special network, will be allowed to focus on the issues that matter without the distraction of myself or my ill-judged comments.

"I deeply regret what was said, will endeavor to work hard at making constructive contributions in the future and will always have a deep appreciation for our viewers -- who are the smartest, most compassionate and discerning of all television audiences."

In his own statement, Griffin said: "Martin Bashir resigned today, effective immediately. I understand his decision and I thank him for three great years with MSNBC. Martin is a good man and respected colleague  -- we wish him only the best."