How did the various Moroccan and Balkan crises raise European tensions before World War I?
Basically, these crises worked to make various of the European countries more suspicious of one another and more desirous of forming alliances to strengthen their positions.
For example, in the Morrocan crises, Germany acted aggressively towards Morocco, thus making France and Britain suspicious of Germany. This drove France and Britain into a tighter alliance aimed at opposing Germany.
Similarly, the Balkan crises led to closer ties between France and Britain and Russia. In those cases, Austria and Germany's actions towards the Slavs of the Balkans worried Russia and made it more afraid of them. Also, the failure of France and Britain to act strongly on Russia's behalf in the Bosnian Crisis of 1908 made it so that they had to, in the future, act strongly for Russia if they wanted to keep Russia as an ally.
In this way, these crises led to some countries becoming more suspicious of others. In addition, it led to various countries becoming more tightly allied to one another for protection. These fears and these ties helped to create a situation in which a relatively small spark could set off a war that would involve most of the countries of Europe.