Queen Blanche, who had administered France during Louis' crusade, died on 1December 1252. Louis made Alphonse and Charles co-regents, so that he could remain in the Holy Land. Margaret II, Countess of Flanders and Hainaut had come into conflict with her son by her first marriage, John of Avesnes. After her sons by her second marriage were captured in July 1253, she needed foreign assistance to secure their release. Ignoring Louis IX's 1246 ruling that Hainaut should pass to John, she promised the county to Charles. He accepted the offer and invaded Hainaut, forcing most local noblemen to swear fealty to him. After his return to France, Louis IX insisted that his ruling was to be respected. In November 1255 he ordered Charles to restore Hainaut to Margaret, but her sons were obliged to swear fealty to Charles. Louis also ruled that she was to pay 160,000 marks to Charles over the following 13 years.