 But only arrived in Surabaya he met his prospective teacher who will carry out hajj to Mecca, next he expressed his desire to learn from him.Then Sheikh Abdul Gani accepted Thawil as a disciple as well as invite him to go to Mecca together.At Masjid al-Haram, Thawil followed the lesson given by Ahmad Zayni Dahlan, Mufti of Mecca, especially regarding "nahwu", fiqh, and al-sīra al-Nabawiyya.