Can't go to jail in Markarth

Solution 1:

The Markarth Guard glitch can happen after completing the two Falmar quests. There are several ways of combating this bug other than reloading a previous save file:

  • Revisit the Shrine of Talos in Markath and clearing out the gaurds again.
  • Trade Markarth for Riften at the peace talks.
  • Become Thane of the Reach.

The bug is listed on Bethesda's forum in the bug report topic.

Solution 2:

I had this same problem, so I loaded an old save. Then, I did the quest up to the part where the guards kill the guy in the temple. During the conversation with them about me being arrested, I noticed I could press the back button. I did and the guards let me buy my way out for 1,000 gold.