It had been attacked and partially reduced by ships of the Royal Navy on 24 July 1815. After his flight from the Roman Republic, Pope Pius IX took refuge at Gaeta in November 1848. He remained in Gaeta until 4 September 1849. On 1 August 1849, the USS "Constitution" while in port at Gaeta, received onboard King Ferdinand II and Pope Pius IX, giving them a 21-gun salute. This was the first time that a Pope set foot on American territory or its equivalent. Finally, in 1860, it was the scene of the last stand of Francis II of the Two Sicilies against the forces of United Italy. The king offered a stubborn defense, shut up in the fortress with 12,000 men and inspired by the heroic example of Queen Maria Sophie after Garibaldi's occupation of Naples. It was not until 13 February 1861 that Francis II was forced to capitulate when the withdrawal of the French fleet made bombardment from the sea possible, thus sealing the annexation of the Kingdom of Naples to the Kingdom of Italy. Cialdini, the Piedmontese general, received the victory title of "Duke of Gaeta". During the functioning of the Government of Montenegro in exile from 1919 to 1924, that supported the Petrović-Njegoš dynasty and opposed the rule of the house of Karađorđević in Yugoslavia (The Greens) were located in Gaeta. After the Risorgimento and until World War II, Gaeta grew in importance and wealth as a seaport. The nearby town of Elena, separated after the Risorgimento and named after the queen of Italy, was reunited to Gaeta following World War I. Mussolini transferred Gaeta from the southern region known today as Campania (formerly Terra di Lavoro, to which it is historically and culturally attached) to the central region of Lazio. After the king dismissed Mussolini in the summer of 1943, the latter was initially taken via Gaeta to the island prison of Ponza. After Italy surrendered to the Allies, however, the town's fortunes began to decline. Recognizing its strategic importance, and fearful of an Allied landing in the area, German troops occupied the city and expelled most of the population. The zone of exclusion began with a five-kilometre border from the historical city centre. Soon after, however, the population was expelled even beyond this point. The Gaetani were finally ordered to leave the area completely.