The effect of surface attachment on ligand binding: studying the association of Mg2+, Ca2+ and Sr2+ by 1-thioglycerol and 1,4-dithiothreitol monolayers.