James Buchanan (April 23, 1791-June 1, 1868) was the 15th president of the United States (1857-1861). He was the only bachelor president and the only resident of Pennsylvania to hold the office of President. As president he was a "doughface" (a northern Democrat allied with the South) who battled Stephen A. Douglas for control of the Democratic Party; Douglas won. Buchanan was a Jeffersonian strict constitutionalist and opposed federal appropriations for most internal improvement projects. Scholars consistently rank him as one of the two or three worst American presidents; although he claimed secession was illegal, he claimed going to war to stop it was also illegal. This inaction laid the grounds for President Abraham Lincoln to fight the American Civil War.