Phosphorescence is the result of a radiative (light emitting) transition involving a change in the spin multiplicity of (in most cases) a molecule from excited state singlet to excited state triplet. This transition is quantum mechanically forbidden as is the transition that leads to light emission. These forbidden transitions are kinetically slow, which introduces a delay between photo-excitation (exposure to light of one wavelength) and emission (release of light of a different wavelength). So-called "glow in the dark" materials are phosphorescent materials with a very long (seconds, minutes, even hours) delay between excitation and emission. Most phosphorescent compounds have triplet lifetimes on the order of milliseconds.
Electrons arranged in molecular orbitals group into pairs which follow the Pauli exclusion principle. In a nutshell, only singlet electrons can populate a single orbital. A singlet excited state results when an electron is promoted while conserving its spin. Relaxation back to the ground state is very fast because the multiplicity doesn't change. Transition to the triplet state involes a forbidden spin flip (electrons cannot exist inbetween the two states in a molecule) to produce the triplet. This phenomenon is known as inter system crossing (ISC) and is kinetically slow, but thermodynamically favorable (it is lower in energy). The energy release between the singlet excited state and the triplet excited state is dissipated vibrationally (see phonon). Once in the triplet state, relaxation back to the ground state neccessarily involves another spin flip to avoid violating the Pauli exclusion principle, which is again kinetically slow, but thermodynamically favorable. In some cases this energy is dissipated by the emission of a photon corresponding to the energy difference between the triplet state and ground state, but often is is dissipated vibrationally (the ratio between these two phenomena for a single molecule is known as the quantum yield of phosphorescence). Since the triplet state is lower in energy than the singlet excited state, the light is lower in energy (red-shifted) than if it had been emitted from a singlet excited state. Many compounds emit both from the singlet and triplet states and by measuring the difference in wavelength between the two the energy difference betwee the excited states can be calculated.
There are many facets to emission from triplet excited states and many people have spent entire careers studying the phenonenon. As one example, a process known as delayed fluorescence occurs when two triplets encouter each other (by delocalization in the solid state or encounter of two species in solution or the gas phase) and additively anhiliate to produce one singlet excited state of higher energy. If this state then emits light it will be of the shorter wavelength associated with fluorescence emission, but on a time scale appropriate for phosphorescence.
Where S is a singlet and T a triplet whose subscript denotes the excited state (zero is ground state). Transitions can occur at higher energy levels, but the first excited state is denoted for simpclicity.