The spread of Islam in India

What caused similarities between the spread of Islam in India and the spread of Islam in Spain? What explains the differences? roughly between 1000 – 1500