By the way people were chained to the pillory, and put in the stocks (most often outside the parish church) right up till the mid-19th century in many countries in Europe. It's not mainly a medieval thing.
This pic (also from Wikpedia, and a free photo) is of a German town pillory erected in the 16th century.