36 Meanwhile, in Egypt the Midianites sold Joseph to Potiphar, one of Pharaoh's officials and captain of the guard.