After the attempt to take over the Weimar Republic failed, Hitler was jailed. Hitler formed a party for legal takeovers through elections. National Socialism had an appeal, especially from the lower-middle class and poor. The general public in Germany lost faith in democracy and associated it with defeat, depression, and inflation. The Nazi party became the largest in parliament and Hitler was made chancellor. Nazis created a one-party dictatorship and outlawed all other political parties. Nazi took over the judiciary, civil service, and military.