After the war with Blambangan and Giri, Majapahit's army became very weak and the moral of the soldiers was at its lowest. This situation was taken by another province, Daha, as a good opportunity to revolt. So in 1478 the king of Daha, Dyah Ranawijaya Girindrawardhana, revolted and led his army to the capital of Majapahit. Another war was broken, and this time Majapahit's army was not ready and they were easily defeated by the rebels. The mighty kingdom of Majapahit who once ruled almost all of Southeast Asia for centuries had finally came to its end. This event was recorded in the Javanese history as "Sirna Ilang Kertaning Bumi" which is a cendrasengkala (text or picture which symbolizes an important date) pointing to the year 1400 Saka or 1478 AD. Bhre Kertabumi, king of Majapahit, and some of his followers managed to escape the war and fled to Demak to seek protection. Finally Bhre Kertabumi embraced Islam and later died in Demak. His grave can still be found near Demak mosque under the name Prabu Darmakusuma. This name was taken from a king in the Hindu epic Bharatyudha, who was forced to leave his kingdom and had to hid in a jungle, a fate which Bhre Kertabumi had to face.
The fall of Majapahit opened an opportunity for Walisongo to build and independent state. Soon afterward Walisongo established the first Islamic kingdom in Java, the Demak Sultanate, with Raden Fatah as its first Sultan in 1478 AD. Many orientalists and manuscripts described that it was Demak Sultanate who destroyed Majapahit. This story is not true and might be a product of those who didn't like Islam and Walisongo. Demak Sultanate were not formed yet at that time, and Walisongo council also had good relationship with Majapahit. Many previous officer in Majapahit were still loyal to Raden Fatah, who was son of previous king of Majapahit, Sri Kertawijaya. Raden Fatah was also Bhre Kertabumi's adopted son. Sunan Ampel was still alive at that time and he always opposed a rebellion against Majapahit who had always been tolerant and protected Islam. If Walisongo intended to destroy Majapahit, why must Sunan Ampel prevented Sunan Giri from attacking its capital? Demak did not attack Majapahit until 40 years after that, but it was not the same old Majapahit because the new king, Girindrawardhana was ruler of Daha who had defeated Majapahit.
Sunan Ampel, leader of Walisongo, died in 1403 Saka (1481 AD) and was buried beside his mosque in Ampel. Sunan Bonang, Sunan Ampel's son, was appointed by the Walisongo council to become their new leader, and the new formation of Walisongo became:
The Demak Sultanate was more like a theocracy than a monarchy. The Walisongo council acted both as advisor and superior to the Sultan. The first Sultan, Raden Fatah, was a member of the council itself. The council however didn't supervise the worldly affairs and detailed management of the Sultanate, they only gave concepts and policies to be performed by the Sultan. Also in 1478 AD, the Walisongo council established the second Sultanate at Cirebon in West Java, with Syarif Hidayatullah as its first Sultan. Like the Sultan of Demak, Syarif Hidayatullah was also member of Walisongo. Syarif Hidayatullah was titled Sunan Gunung Jati. These new Sultanates soon found many old Hindu kingdoms in the island who threatened them: Pajajaran kingdom in West Java, Pengging kingdom in Central Java, and the Daha kingdom who replaced Majapahit in East Java.
Months after the birth of the Cirebon Sultanate, Pajajaran kingdom sent an army to Cirebon. King of Pajajaran, Prabu Siliwangi, was grandfather of Sunan Gunung Jati, the Sultan of Cirebon, so he didn't send the army to destroy the Sultanate but only to ask his grandson to remain under his kingdom. The army itself was very small, only 60 soldiers strong and was led by Temenggung Jagabaya. Sunan Gunung Jati refused his grandfather's request and with his persuassion the army defected to his side. To prevent further threat from Pajajaran and to strengthen their position, the Cirebon Sultanate expanded their influence to other provinces within the Pajajaran kingdom. Sunan Gunung Jati also expanded Muara Jati seaport to increase trade and strengthen the economy. Trade relations were made as far as China, and soon many Chinese merchants moved to Cirebon and build communities. Trade relation with China was then followed by political relation with the Ming Dynasty in China. Sunan Gunung Jati even married a princess from China, Ong Tien, who was titled Nyi Ratu Rara Sumanding. In just a few years Cirebon had become a powerful kingdom in West Java which enabled Sunan Gunung Jati to persuade other provinces to join the new Sultanate and embraced Islam. These provinces are: Surantaka, Japura, Wanagiri, Galuh, Talaga, and Singaparna. Pajajaran became worried with this but Prabu Siliwangi still didn't want to attack his own grandson.
In 1511, a blow to the Moslem power in Southeast Asia came when Portuguese fleet attacked and conquered Malacca in the Malay Peninsula. The Portuguese were Catholics and had waged a holy war against Islam in Europe, Africa, Middle East, and now in Southeast Asia. Malacca was the most important Islamic seaport in this region, and since its fall to Portuguese army, the trade route and the spread of Islam was disturbed. In the following year the Portuguese also attacked the Moslem kingdoms in Sumatra but failed to conquer them. Then the Portuguese planned to attack the Moslem Sultanates in Java by making relations with Pajajaran kingdom in West Java and Majapahit kingdom in East Java. Portuguese envoy to Pajajaran was welcomed by the king and they were allowed to build a garisson in Sunda Kelapa, a small port just 200 miles from Cirebon. Demak and Cirebon were aware of this new threat and planned a strategy to counter the Portuguese, which already started to make alliance with Prabu Udara, successor of Girindrawardhana.
In 1513 Supit Urang Ranggaprana, ally of Prabu Udara, started an agression to Demak Sultanate. The incident escalated into a war between Demak and Daha, when Prabu Udara decided to help his ally. Prabu Udara was also helped by Prabu Adyadiningrat from Pengging and Adipati Klungkung from Bali. They are ruler of Hindu kingdoms who didn't like the growth of Islam in Java. They hoped to eliminate the Moslem power from the island by helping Prabu Udara in his war against Demak. Demak army was led by Sunan Ngudung and Ja'far Shadiq, his son. Demak was also helped by Arya Damar, ruler of Palembang in Central Sumatra. Almost five years had passed when in a big battle on the banks of Sedayu river, Prabu Adyadiningrat, king of Pengging, was finally killed by Sunan Ngudung's army but Sunan Ngudung himself was also killed by Adipati Terung, a general of the Majapahit's army. With Sunan Ngudung's death the Demak army retreated to reinforce their strength. Sunan Ngudung was titled "Pengulu Rahmatullah" to honor his heroism in the war to defend Islam. Sunan Ngudung's place in Walisongo council was then replaced by his own son, Ja'far Shadiq, who was titled Sunan Kudus. Ja'far Shadiq was also appointed to led Demak's army in a last expedition to attack Prabu Udara's palace in Trowulan, Majapahit's previous capital. Prabu Udara was killed in the battle, and Adipati Terung finally surendered and was brought to Demak. Eventhough he had killed a member of Walisongo, he was pardonned by the other member of the council, a common Sufi act. The sincerity of Walisongo touched Adipati Terung, and he voluntarily embraced Islam. Prabu Udara's followers who didn't want to surrender to Demak, escaped to hide in remote places such as Mount Bromo and Mount Lawu. Many other escaped to Bali with Klungkung's army, including many Hindu artisans from the palace. This explains why so many people in Bali had talents in art until now. With the defeat of Prabu Udara, Walisongo can focused their attention to face the Pajajaran Kingdom and the Portuguese.
In 1518, Raden Fatah died and was buried near Demak Mosque. Raden Fatah's son, Adipati Unus, became the second Sultan of Demak and was titled Pangeran Sabrang Lor. The death of Raden Fatah, Sunan Ngudung, and Sunan Giri who died a few years before that, forced the council of Walisongo to appoint new Sufi masters to fill their places. The new formation of Walisongo became:
In 1521, a combined fleet of Demak and Cirebon departed to attack the Portuguese in Malacca. The Moslem army was led by Adipati Unus, Sultan of Demak. The war was bloody and both side suffered heavy losses, but the Moslem army could not withstand Portuguese firepower. Adipati Unus was killed in the war and the fleet had to retreate from Malacca and went back to Java. Walisongo then appointed Pangeran Trenggono to become the third Sultan of Demak. He was then titled Sultan Ahmad Abdul Arifin or Sultan Trenggono. The Portuguese base in Malacca was too strong for Demak to defeat, so Walisongo changed their target to the Portuguese base in Sunda Kelapa, which was not very strong yet. But this base was also protected by Pajajaran kingdom, who had made an alliance with the Portuguese. But the king of Pajajaran wasn't aware that not every province in Pajajaran agreed with his alliance with Portuguese. Sunan Gunung Jati quickly made contact with these local rulers and asked them to support his plan to drive away the foreigners. He also sent his son, Maulana Hassanuddin, to preach at Banten, a province in the westernmost part of Java. The ruler of Banten finally accepted Islam and agreed to support the Walisongo plan to attack Sunda Kelapa.
Sultan Trenggono appointed Fatahillah to led the Moslem army to conquer Sunda Kelapa.
-----------(to be continued)----------