A Pennsylvania state lawmaker who is facing child pornography possession charges resigned Sept. 18, just hours after his arrest spurred condemnation and calls for him to step down.

Former Pennsylvania Sen. Mike Folmer, R-Lebanon, was charged Sept. 17 by the state Attorney General's Office after agents confronted him, saying they acted on a tip from an online social media provider that a user had uploaded an image of suspected child pornography on its service.

Investigators allegedly found two images of child pornography on Folmer's cellphone after they executed a search warrant at his house in Lebanon County and asked him to turn it over.

Senate President Pro Tempore Joe Scarnati, R-Jefferson, and Majority Leader Jake Corman, R-Centre, said in a statement they received Folmer's resignation letter after they called Folmer to insist on it earlier in the day.

Folmer's signed, one-sentence letter is addressed to Scarnati and Corman, and says, "It is with this letter that I announce my intention to resign from the Senate of Pennsylvania effective September 18, 2019."

Neither Folmer nor a lawyer representing him have returned messages seeking comment. In their statement, Scarnati and Corman said they were "sickened and disturbed" by the allegations against Folmer.

Gov. Tom Wolf had called publicly for Folmer's resignation, saying the charges against Folmer are "disgusting and beyond comprehension, and show he has taken advantage of the trust and privilege afforded by the people of Pennsylvania."

Folmer, 63, was charged with possession of child pornography and criminal use of a communication facility, both felonies. Folmer was arraigned Sept. 17 and posted bail of $25,000, a court official said.

In February, the National Center for Missing and Exploited Children received a notification from the social media site Tumblr that a user had uploaded at least one image that contained suspected child pornography in December 2017, according to court papers submitted by the attorney general's office.

Investigators then traced the Tumblr account to Folmer's email address and home address, they said. After they confronted him, he agreed to speak to investigators without an attorney present, the court papers said.

Attorney General Josh Shapiro on Sept. 17 announced the charges against Folmer.

"This defendant serves as a state senator and was entrusted to honor and represent his community in the Pennsylvania Capitol," Shapiro said in a statement. "Our office arrested Mr. Folmer for possession of child pornography and charged him with sexual abuse of children, possession of child pornography, and criminal use of a communication facility. I will continue to say it—no one is above the law, no matter what position of power they hold. I will continue to work to protect children and hold those who abuse them accountable."

The case will be prosecuted by Senior Deputy Attorney General Christopher Jones, the state Attorney General's Office statement said.

"Michael Folmer stated that he had been dealing with some personal problems/issues and that he had received child pornography through his Tumblr blog," an agent of the office wrote in the court papers.

Folmer was elected to a fourth four-year term in November and had chaired the Senate State Government Committee, where he had spent considerable time recently working on election reform bills.

Folmer was first elected in 2006, knocking off the Senate's then-sitting Republican majority leader in that year's anti-pay raise backlash.

Long considered one of the chamber's most conservative members, Folmer was crucial to helping swing Republican votes behind a bill to legalize medical marijuana in 2016. He routinely pulls a miniature copy of the U.S. Constitution from his breast pocket when speaking publicly to emphasize a point.

On one recent hot-button issue, Folmer had opposed legislation to lift legal barriers that block long-ago victims of child sexual abuse from suing institutions, such as the Roman Catholic Church, that may have covered up the crimes.

Folmer's resignation leaves the 50-seat Senate with a 27-22 Republican majority. It will be up to Lt. Gov. John Fetterman to set a special election to fill the remainder of Folmer's term, through 2022. The heavily Republican district includes Lebanon County and parts of Dauphin and York counties.