It was in this period that the Spanish Christians were first able to take the fighting to mainland present-day Morocco: in 1260 and 1267 they attempted an invasion, but both attempts were defeated. After gaining a foothold in Spain, the Marinids became active in the conflict between Muslims and Christians in Iberia. To gain absolute control of the trade in the Strait of Gibraltar, from their base at Algeciras they started the conquest of several Spanish towns: by the year 1294 they had occupied Rota, Tarifa and Gibraltar.