Charged fluid sphere in general relativity