Wei Zhaodu

[4] Wei Zhaodu passed the imperial examinations in the Jinshi class in 867, during the reign of Emperor Yizong,[3] and thereafter entered governmental service.

[5] In the middle of the Qianfu era (874-879) of Emperor Yizong's son and successor Emperor Xizong, Wei Zhaodu went through a series of promotions — becoming a supervisory official at one of the ministries at the executive bureau of government (尚書省, Shangshu Sheng), then becoming in charge of drafting edicts and being made Zhongshu Sheren (中書舍人), a mid-level official at the legislative bureau (中書省, Zhongshu Sheng).

[3] When Emperor Xizong fled from Chang'an to Chengdu in early 881 due to the attack on Chang'an by the major agrarian rebel Huang Chao,[6] Wei followed Emperor Xizong there, and once they arrived in Chengdu he was made deputy minister of defense (兵部侍郎, Bingbu Shilang) as well as chief imperial scholar (翰林學士承旨, Hanlin Xueshi Chengzhi).

[6] It was said that the reason why he was made chancellor was that he was an associate of the powerful eunuch Tian Lingzi, with whom he established a relationship through the Buddhist monk Shiche (釋澈).

As a result, in 886, when the warlords Wang Chongrong, Li Keyong, Zhu Mei, and Li Changfu rose against Tian (forcing Emperor Xizong to again flee Chang'an, to Xingyuan (興元, in modern Hanzhong, Shaanxi)) and demanded Tian's death, they also demanded Wei's death, although no subsequent actions were taken against Wei, who remained chancellor.

[5] Shortly after, Emperor Zhaozong received petitions from Gu Yanlang the military governor (Jiedushi) of Dongchuan Circuit (東川, headquartered in modern Mianyang, Sichuan) and the former imperial guard general Wang Jian, both of whom were attacking Tian Lingzi's brother Chen Jingxuan the military governor of Xichuan Circuit (西川, headquartered in modern Chengdu).

As Emperor Zhaozong resented Tian (who was then no longer at the imperial government and evading punishment by putting himself under his brother's protection), he ordered an edict that Chen return to Chang'an to serve as an imperial guard general, while making Wei the military governor of Xichuan, still carrying the Zhongshu Ling title as an honorary title.

)[9] In 893, after the imperial government had been defeated in an attempt to defeat Li Maozhen (who had been made the military governor of Fengxiang Circuit (鳳翔, headquartered in modern Baoji) but then was no longer following imperial orders and finding ways to intimidate the imperial government) and Li Maozhen's ally Wang Xingyu the military governor of Jingnan Circuit (靜難, headquartered in modern Xianyang, Shaanxi), Emperor Zhaozong was forced to order the chancellor Du Rangneng, who had overseen the operations, to commit suicide.