Who is the only US president elected from Pennsylvania?

James Buchanan, the 15th President of the United States.