No, Tripoli is the capital of Libya. Tangier is in Morocco.
To reenforce this answer I copy from the Encyc Brittannica:
French Tanger , Spanish Tánger , Arabic Ṭanjah
port and principal city of northern Morocco. It is located on a bay of the Strait of Gibraltar 17 miles (27 km) from the southern tip of Spain; Tétouan lies about 40 miles (65 km) to the southeast. Pop. (2004) 669,685.
AND …
Arabic Ṭarābulus , in full Ṭarābulus al-Gharb ("The Western Tripoli")
capital city of Libya. Situated in northwestern Libya along the Mediterranean coast, it is the country's largest city and chief seaport.
Tangier is a large city in northern Morroco.
It is the capital of the Tangier-Tetouan Region and of the Tangier-Asilah prefecture of Morocco.
Bombardment of Tangiers happened on 1844-08-06.
A Moroccan since Tangiers is the capitol of Morocco.
No. (1) Africa is a continent, not a country, so it has no capital. (2) Morocco is a country, not city, so it cannot serve as a capital. (3) Morocco is the only African nation to have been ejected from the African Union.
Tangiers is a Moroccan city with a Muslim-majority population.
Tangiers - 1985 is rated/received certificates of: West Germany:16
Summit County
Tangerine
The Tangiers Grand Mosque of Morocco is a place of worship for Sunni Islam of the Maliki School.
Tangerine
tangerina
Morocco
Tangiers