After his death, the succession was disputed. The regent Malik al-Afdal placed Mustansir's younger son Al-Mustali Biallah on the throne. This was contested by the elder son Nizar ibn al-Mustansir, who was defeated and died in prison. This dispute resulted in the split into two branches, lasting to this day, the Nizari and the Musta'li. The Musta'li recognized Imams:  Hafizi Ismaili Muslims claimed that al-Amir died without an heir and was succeeded as Caliph and Imam by his cousin al-Hafiz. The Musta'li split into the Hafizi, who accepted him and his successors as an Imam, and the Tayyibi, who believed that al-Amir's purported son At-Tayyib was the rightful Imam and had gone into occultation. The Tayyibi recognized Imam:  The Tayyibi branch continues to this day, headed by a Da'i al-Mutlaq as vice-regent in the imam's occultation. The Tayibbi have broken into several branches over disputes as to which Da'i is the true vice-regent. The largest branch are the Dawoodi Bohra, and there are also the Sulaimani Bohra and Alavi Bohra. The Hafizi recognized Imams:  The Hafizi sect lived on until the 14th century in Egypt and Syria, but died out by the end of the 14th century. Following the death of Shams al-Din Muhammad, the Nizari Isma'ili split into two groups: the Mu'mini Nizari (or, Muhammad-Shahi Nizari) who considered his elder son 'Ala' ad-Din Mumin Shah to be the next Imam followed by his son Muhammad Shah, and the Qasimi Nizari (or, Qasim-Shahi Nizari) who consider his younger son Qasim Shah to be the next Imam