In 874, Wang Xianzhi (who, like Huang Chao, was a salt privateer) and Shang Junzhang (尚君長) raised an army at Changyuan (長垣, in modern Xinxiang, Henan).
By 875, he had repeatedly defeated Xue Chong (薛崇), the military governor of Tianping Circuit (天平, headquartered in modern Tai'an, Shandong), in battle.
Late in 876, Wang was sought to parlay his victories into a peaceful submission to Tang authority, in which he would be generously treated by the throne.
However, Huang, who did not receive a commission as part of this arrangement, angrily stated:[1] "When we started the rebellion, we made a grand oath and we have marched through great distances with you.
[1] Huang Chao subsequently roamed throughout central China, and his campaign took him into many engagements with Tang forces: In the spring of 878, Huang was besieging Bo Prefecture (亳州, in modern Bozhou, Anhui), when Wang Xianzhi was crushed by Zeng at Huangmei (黃梅, in modern Huanggang, Hubei) and killed.
Huang, instead, claimed the title of Chongtian Dajiangjun (衝天大將軍, "Generalissimo Who Charges to the Heavens") and changed the era name to Wangba, to show independence from the Tang regime.
However, during this march, he was attacked by the Tang officers Zhang Lin (張璘) and Liang Zuan (梁纘), who were subordinates of Gao Pian, the military governor of Zhenhai Circuit (鎭海, headquartered in modern Zhenjiang, Jiangsu), and was defeated several times.
As a result of these battles, a number of Huang's followers, including Qin Yan, Bi Shiduo, Li Hanzhi, and Xu Qing (許勍), surrendered to the Zhenhai troops.
In fall 879, he attacked Lingnan East's capital Guang Prefecture, capturing it after a one-day siege and taking Li Tiao captive.
[2] Huang himself followed Xiang's advance and went through Jiangling to attack Xiangyang, the capital of Shannan East Circuit (山南東道).
He was, however, defeated by the joint forces of Shannan East's military governor Liu Jurong (劉巨容) and the imperial general Cao Quanzhen (曹全晸), who further pursued him all the way to Jiangling.
Many circuits thus sent troops to Huainan[2] With his forces repeatedly defeated by Zhang and also suffering from plagues, Huang, then stationed at Xin Prefecture (信州, in modern Shangrao), decided to try to bribe his way out of his predicament.
This occurred as some 3,000 Ganhua soldiers were heading to Yin River to participate in the defense operations there, and they went through Xu Prefecture (許州, in modern Xuchang), the capital of Zhongwu Circuit (忠武).
Xue met them and calmed them down, but this in turn caused the Zhongwu soldiers and the populace of Xu Prefecture to be angry at his lenient treatment of them.
In response, the troops that other circuits had stationed at Yin River scattered, leaving the path wide open for Huang.
Meanwhile, though, the chancellors Doulu Zhuan and Cui Hang, believing that imperial forces would not be able to stop Huang from reaching Luoyang and Chang'an, suggested that Emperor Xizong prepare to flee to Xichuan Circuit (西川, headquartered in modern Chengdu, Sichuan), where Chen Jingxuan, the brother of the powerful eunuch Tian Lingzi, was military governor.
Emperor Xizong, however, wanted to also make one last attempt to defend Tong Pass, between Luoyang and Chang'an, and therefore sent the imperial Shence Army (神策軍) officers Zhang Chengfan (張承範), Wang Shihui (王師會), and Zhao Ke (趙珂)—whose soldiers were ill-trained and ill-equipped, as the Shence Army soldiers' families were largely wealthy and were able to pay the poor and the sick to fill in for them—to try to defend it.
Meanwhile, Luoyang fell quickly, and Qi withdrew to Tong Pass as well, and submitted an emergency petition stating that his troops were fatigued, hungry, and without supplies, with no apparent imperial response.
Meanwhile, Tian had recruited some new soldiers, who were also ill-trained but relatively well-equipped, and sent them to the front, but by the time they reached there, Tong Pass had already fallen, and the troops from Boye Army (博野軍) and Fengxiang Circuit (鳳翔, headquartered in modern Baoji, Shaanxi), also sent to the front to try to aid Zhang, became angry at the good equipment (including warm clothes) that Tian's new soldiers had, and mutinied, instead serving as guides for Huang's forces.