  Intrinsic alignments of galaxies have been shown to contaminate weak
gravitational lensing observables on linear scales, $r>$ 10 $h^{-1}$Mpc, but
studies of alignments in the non-linear regime have thus far been inconclusive.
We present an estimator for extracting the intrinsic alignment signal of
galaxies around stacked clusters of galaxies from multiband imaging data. Our
estimator removes the contamination caused by galaxies that are gravitationally
lensed by the clusters and scattered in redshift space due to photometric
redshift uncertainties. It uses posterior probability distributions for the
redshifts of the galaxies in the sample and it is easily extended to obtain the
weak gravitational lensing signal while removing the intrinsic alignment
contamination. We apply this algorithm to groups and clusters of galaxies
identified in the Sloan Digital Sky Survey `Stripe 82' coadded imaging data
over $\sim 150$ deg$^2$. We find that the intrinsic alignment signal around
stacked clusters in the redshift range $0.1<z<0.4$ is consistent with zero. In
terms of the tidal alignment model of Catelan et al. (2001), we set joint
constraints on the strength of the alignment and the bias of the lensing groups
and clusters on scales between 0.1 and $10\,h^{-1}$ Mpc, $b_LC_1\rho_{\rm crit}
= -2_{-14}^{+14} \times 10^{-4}$. This constrains the contamination fraction of
alignment to lensing signal to the range between $[-18,23]$ per cent below
scales of 1 $h^{-1}$ Mpc at 95 per cent confidence level, and this result
depends on our photometric redshift quality and selection criteria used to
identify background galaxies. Our results are robust to the choice of
photometric band in which the shapes are measured ($i$ and $r$) and to centring
on the Brightest Cluster Galaxy or on the geometrical centre of the clusters.
