  Gamma-rays from hadronic collisions are expected from supernova remnants
(SNRs) located near molecular clouds. The temperature on the shock interacting
with the dense environment quickly reaches $10^5$ K. The radiative losses of
plasma become essential in the evolution of SNRs. They decrease the thermal
pressure and essentially increase the density behind the shock. The presence of
ambient magnetic field may considerably alter the behavior of the
post-adiabatic SNRs comparing to hydrodynamic scenario. In the present paper,
the magneto-hydrodynamic simulations of radiative shocks in magnetic field are
performed. High plasma compression due to the radiative losses results also in
the prominent increase of the strength of the tangential component of magnetic
field behind the shock and the decrease of the parallel one. If the strength of
the tangential field before the shock is higher than about $3\mathrm{\mu G}$ it
prevents formation of the very dense thin shell. The higher the strength of the
tangential magnetic field the larger the thickness and the lower the maximum
density in the radiative shell. Parallel magnetic field does not affect the
distribution of the hydrodynamic parameters behind the shock. There are almost
independent channels of energy transformations: radiative losses are due to the
thermal energy, the magnetic energy increases by reducing the kinetic energy.
The large density and high strength of the perpendicular magnetic field in the
radiative shells of SNRs should result in considerable increase of the hadronic
gamma-ray flux comparing to the leptonic one.
