Who was the leader of Austria-Hungary during World War 1 - Franz Joesph or Franz Ferdinand?

Franz Ferdinand was killed by Gavrilo Princip in 1914, just before the war.