The region around the Chang Jiang delta was established as a trading centre by the 10th century, a generally prosperous zone within which the small port of Shanghai flourished for centuries. Japanese pirates were attracted by this wealth, and after numerous attacks, Shanghai built a protective wall in the 16th century. The wall surrounded the old city centre until 1912, just south of the Bund in a circular area defined by Renmin and Zhonghua roads. While the wall eventually deterred the Japanese pirtes, it failed to impede Western colonial intrusions. As a result of the Opiun War in the 1840s, the British imposed the Treaty of Nanjing upon China, which, among many things, opened up Shanghai to Westerners.
Foreign concession areas occupied most of what is now central Shanghai, save gor the old walled Chinese part of the city. Shanghai rapidly became the place to be - a city with the liveliest culture, the most opulent dance halls, the largest volume of business, the tallest buildings.
New idea also allowed for radicalism- -a Shanghai tradition. The Communist Party was founded in the city in 1921, and the Cultural Revolution of the 1960s not only began in Shanghai, but had its headquarters here. Despite the enthusiasm of the Red Guards to demolish everything not defined as Socialist Realism - and that included anything foreign, Buddhist, or simply old - a surprising number of buildings from colonial times have survived in the city. Many may not survive China's modernising zeal.