The oldest existing photograph of a US President (John Quincy Adams) was discovered when it was bought for 50 cents in an antique shop.