The density function theory has been proposed for studying the structural properties of electrolytes containing uniformly charged hard-spherical ions. The calculated result shows good agreement with the corresponding Monte Carlo simulation data of Bohinc et al. [J. Chem. Phys. 145, 234901 (2016)]. The results confirm that the attraction between like-charged planar surfaces is the results of the intra-ionic correlation and depends strongly on the charge distribution of hard-sphere ions.