A new cap has been installed on the leaking well in the Gulf of Mexico, offering hope of containing the gusher for the first time since BP's deepwater rig exploded in April.