Prithvi lived in Lat Kot when he was given the throne of Delhi. Lal Kot was built by the Tomar ruler Anangpal I in about 731 A.D and said to have been rebuilt by Anangpal II in 11th century when he transferred the Capital from Kannauj to Delhi. The Chauhans defeated the Tomars in 12th century AD. Prithviraj extended the old city of Lal Kot and added ramparts and moat. Prithviraj was also known as Rai Pithora and thus it came to be known as Qila-I-Rai Pithora, the first city of Delhi. Lal Kot was an oblong structure having seven gates-Sohna, Ranjit, Ghazni, Hauz Rani, Barka, Budaun and Maya. Only ramparts are visible near the Qutub Minar although it is said to have had several Jain and Hindu temples. Mohammad Ghori invaded India towards the end of the 12th century AD from Afghanistan and defeated Prithviraj and occupied Delhi. There is said to be a life size statue of Prithvi was built.