Fakhr al-Mulk ibn Ammar was the last qadi of Tripoli, from 1099 to 1109, before the city was taken by the Crusaders.