Somerset played an important part in defeating the spread of the Danes in the 9th century. The Anglo-Saxon Chronicle records that in 845 Alderman Eanwulf, with the men of Somersetshire (Sumorsǣte), and Bishop Ealstan, and Alderman Osric, with the men of Dorsetshire, conquered the Danish army at the mouth of the Parret. This was the first known use of the name Somersæte. The Anglo-Saxon Chronicle reports that in January 878 the King Alfred the Great fled into the marshes of Somerset from the Viking's invasion and made a fort at Athelney. From the fort Alfred was able to organize an resistance using the local militias from Somerset, Wiltshire and Hampshire.