Today is battle of the Boyne day, marking the 310th anniversary of King Billy's famous victory in Ireland and the triumph of Protestantism. For Orangemen in Northern Ireland and beyond, July 12 is an almost sacred day.

This is odd, because the battle was actually fought on July 1, and King William was on the side of the Pope.

The date is easily explained: in William's day Britain was still using the old Roman calendar devised by Julius Caesar. More than half a century after the battle, the Julian system was superseded by the Gregorian; 11 days were wiped from British calendars; and July 1 became July 12.

The papal alliance, which many Protestants prefer to gloss over, must also be seen in the context of the times, in which dynastic ambition often outweighed religious allegiance or scruple.

King William III was the Protestant head of the Dutch royal house of Orange. He was married to Mary, the Protestant-raised daughter of King James II of Britain, a convert to Catholicism.

James's naked ambition to lead Britain back into the old church alienated the court and many of his subjects. In 1688, powerful establishment figures invited William and Mary to take the throne. But when they landed in England, the royal army, led by John Churchill, the future Duke of Marlborough, defected and James fled to France.

But he had friends among his mostly Catholic subjects in Ireland and a redoubtable ally in Louis XIV of France, then at the height of a ruthless drive to make himself Europe's overlord.

William was rabidly anti-French, and was an eager recruit to the alliance of powers which opposed Louis. Other leaders of the League of Augsburg - later the Grand Alliance - included the Austrian emperor, Leopold, and Pope Alexander VIII.

Thus, when James landed in Ireland in a doomed attempt to win back his throne and promote the Catholic faith, he was indirectly fighting the Pope. And William, defending the Protestant ascendancy in both of John Bull's islands, was at the same time advancing the cause of the Vatican.

For all that, the victory at Oldcastle, near the mouth of the River Boyne, was hugely significant for Ireland and Britain. It glued William and Mary firmly on the throne, and consolidated the momentous changes in the British way of government known as the Glorious Revolution.

King James was the last of the Stuart kings who hankered after absolute rule. King Billy, though he was no democrat, astutely accepted the supremacy of parliament. In that sense, the battle of the Boyne, though relatively minor in military significance, was a landmark event in British affairs, as well as a continuing landmine in Irish history.