Ancient Greek philosophy

Ancient Greek philosophy started in the 6th century BC and continued during the Hellenistic period and Roman Empire. Philosophy was a way to think about the world. The term was invented in Greece. Back then it included the sciences, maths, politics, and ethics.
Greek philosophy is one of the foundations of Western culture. It has been referred to in Rome, Islamic philosophy, and the Renaissance and the Age of Enlightenment.
Greek philosophy may have been somewhat influenced by the ancient Near East. Some of the most important philosophers are Socrates, Aristotle, and Plato. Alexander the Great even learned Greek philosophy before conquering the Persian empire.
Many philosophers thought mathematics was important to all knowledge, and Euclid was one of the founders of mathematical thought. He wrote a famous book on geometry called The Elements.
Before Socrates.
Many sophists were active, including Protagoras. They are known mostly from what Socrates said against them.
Pythagoras may have been a mystic or a rationalist. We do not know that much. He is known for the Pythagorean theorem.
Classical Greek philosophy.
Socrates.
Socrates may have been born in Athens in the 5th century BCE. He was very important. Athens was a center of learning. People went there to talk about ideas. However, it became a crime to philosophize. Some people were accused. But Socrates was the only one who was killed in 399 BCE (see Trial of Socrates). In his defense speech (presented by Plato), he says it's because others were jealous.
He is considered the founder of political philosophy.
Many of his conversations end without a conclusion. So he is known for the Socratic method. 
Socrates taught that no one wants what is bad, and so if anyone does something bad, it must be unintentional out of ignorance; he concludes that all virtue is knowledge. He often talks about his own ignorance.
Aristotle influenced Plato's dialogues and Plato's student Aristotle. Their ideas influenced the Roman empire, the Islamic Golden Age, and the Renaissance.
Plato.
Plato was from Athens. He came a generation after Socrates. He wrote thirty-six dialogues and thirteen letters to Socrates, though some may be fake.
Plato's dialogues have Socrates. Along with Xenophon, Plato is the primary source of information about Socrates' life. Socrates was known for irony and not often giving own opinions. 
Plato wrote the "Republic", the "Laws", and the "Statesman". The Republic says there will not be justice in cities unless they are ruled by philosopher kings; those who enforcing the laws should treat their women, children, and property in common; and the individual should tell noble lies to promote the common good. The "Republic" says that such a city is likely impossible as it thinks philosophers would refuse to rule and the people would refuse to be ruled by philosophers.
Plato is known for his theory of forms. It says that there are non-physical abstract ideas that have the highest form and most real kind of reality.
Aristotle.
Aristotle moved to Athens in 367 BC and began to study philosophy. He studied at Plato's Academy. He left Athens twenty years later to study botany and zoology. He became a teacher of Alexander the Great and returned to Athens ten years later to create his own school: the Lyceum. At least twenty-nine of his books have survived, known as the "corpus Aristotelicum." He wrote about logic, physics, optics, metaphysics, ethics, rhetoric, politics, poetry, botany, and zoology.
Aristotle disagreed with his teacher Plato. He criticizes the governments in Plato's "Republic" and "Laws", and refers to the theory of forms as "empty words and poetic metaphors." He cares more about empirical observation and practical concerns.
Aristotle was not that famous during the Hellenistic period, when Stoic logic was still popular. But later people popularized his work, which influenced Islamic, Jewish, and Christian philosophy. Avicenna referred to him simply as "the Master"; Maimonides, Alfarabi, Averroes, and Aquinas referred to him as "the Philosopher."
Hellenistic philosophy.
During the Hellenistic and Roman periods, many different schools of thought developed in the Hellenistic world and the Greco-Roman world. Greeks, Romans, Egyptians, Syrians and Arabs who contributed. Persian philosophy and Indian philosophy also had an influence. 
The spread of Christianity followed by the spread of Islam further spread Hellenistic philosophy. It influenced the three Abrahamic traditions: Jewish philosophy, Christian philosophy, and early Islamic philosophy.
Islam.
During the Middle Ages, Greek ideas were largely forgotten in Western Europe due to the Migration Period, which caused a decline in literacy. In the Byzantine Empire Greek ideas were kept and studied. 
After the expansion of Islam, the Abbasid caliphs started translating Greek philosophy. Islamic philosophers such as Al-Kindi (Alkindus), Al-Farabi (Alpharabius), Ibn Sina (Avicenna) and Ibn Rushd (Averroes) reinterpreted these works. During the High Middle Ages Greek philosophy re-entered the West through translations from Arabic to Latin and also from the Byzantine Empire. 
The re-introduction of these philosophies, plus new Arabic commentaries, had great influence on Medieval philosophers such as Thomas Aquinas. 
Still Arab translators threw away books that disagreed with Islam. For example, Al-Mansur Ibn and Abi Aamir burned the Al-hakam II library in Córdoba in 976.