Talladega Mayor Larry Barton walks out of the voting booth during an election Tuesday, Aug. 25, 2015, in Talladega, Ala.

TALLADEGA, Ala. -- Voters in an Alabama city best known for its motor speedway were deciding Tuesday whether to give a fifth term in office to a mayor who has a prison record and is recovering after being beaten up at a barber shop.

Talladega Mayor Larry Barton faced challenges from opponents Vann Caldwell and Jerry Cooper Sr. in the city's municipal elections -- a campaign run in the shadow of Barton's record and more recently a salacious scandal involving allegations of illicit sex.

The city of roughly 16,000 is home to the Talladega Superspeedway which hosts major auto racing events.

Barton served about three years in prison in the 1990s after being convicted of defrauding the city. Prosecutors said he had city officials issue checks to a fictitious worker and cashed them himself.

On Aug. 8, he was assaulted about 55 miles west of Talladega outside a barbershop where he works part-time in the Birmingham suburb of Vestavia Hills.

Some voters said Barton's appeal and charitable reputation may help him find his way back to the mayor's office despite his past, as other politicians have done, including former Providence, Rhode Island, Mayor Buddy Cianci and former Washington, D.C., Mayor Marion Barry.

"He may get re-elected, I didn't vote for him," said Ken Shaddix as he left a voting precinct. "There's a lot of people I don't like that do a good job."

Barton was beaten up more than two weeks ago amid claims from attorney Stewart Springer that Barton was secretly recorded having an affair with the wife of the beating suspect, Benny Green.

Springer said he had represented Green -- Barton's former friend -- in his divorce case, and Springer said he saw the videos himself. Divorce court records said the encounters were recorded in the rear office of a liquor store the Greens own.

In an interview, Barton acknowledged keeping an office in the store and serving as its bookkeeper, but denied the sexual allegation. Court records said the videos were presented in February. Barton said the timing of the attack suggested it may have been a smear tactic ahead of the city's election.

Police said Green, 71, is accused of hitting Barton with a bat and trying to flee the scene on a bicycle. He was charged with assault. A voice message and email to an attorney listed for him in court documents wasn't immediately returned.

Amid the political campaign signs dotting the well-kept yards in Talladega's quiet, tree-lined neighborhoods, Barton and his wife, Mary, drove up to a voting precinct Tuesday with their own signs that simply read "BARTON" in red letters on both sides of their car. Barton, who appeared to be recovering from multiple bruises and cuts, walked alongside his wife and greeted voters as they trickled into a recreation center Tuesday afternoon.

"A lot of people have been good to me for four terms," Barton said quietly outside the voting precinct. "Whether this last little incident hurts me, I don't know. We'll just have to see how it plays out."

Barton ran for mayor several times after his federal prison sentence and lost runoffs before he was re-elected in 2011. Some who spoke briefly and traded jokes with Barton before walking up the recreation center's steps later said they didn't vote for him and declined to give their names or be interviewed.

As he left the polling place, Daniel Dase said Barton's federal conviction and accusations of being caught on tape with another man's wife has left they city with a black eye of its own. Some residents say the city needs to clean up its reputation in hopes of attracting more economic development besides the racetrack.

"I think Talladega has an image problem right now and that's one thing we have to combat," Dase said. "And then, we've been hurt a lot with industry over the last 10, 15 years, and you know, Talladega has to change. We need everything we can to put forth our best image and present ourselves and draw things in."

If the three-way race for mayor ends without a clear winner, a runoff election will be held be Oct. 6.