  We consider competing pair-density-wave (PDW) and $d$-wave superconducting
states in a magnetic field. We show that PDW order appears in the cores of
$d$-wave vortices, driving checkerboard charge-density-wave (CDW) order in the
vortex cores, which is consistent with experimental observations. Furthermore,
we find an additional CDW order that appears on a ring outside the vortex
cores. This CDW order varies with a period that is twice that of the
checkerboard CDW and it only appears where both PDW and $d$-wave order
co-exist. The observation of this additional CDW order would provide strong
evidence for PDW order in the pseudogap phase of the cuprates. We further argue
that the CDW seen by nuclear magnetic resonance at high fields is due to a PDW
state that emerges when a magnetic field is applied.
