As we know Benzene undergo Electrophilic Substitution Reactions. In case of substituted Benzene the incoming Electrophile is substituted either at Orto , Para position or Meta position. If the substituent is Electron Withdrawing in Nature then the Electrophile will go to meta position. When the substituent id Electron Donating in Nature then the incoming electrophile will be directed to ortho and para position.
In Benzenesulfonic Acid the substituent is Sulfonate (-SO₃H), it has a strong electron withdrawing effect. So on Nitration the Nitro group will be oriented to meta position and 3-nitrobenzenesulfonic acid is formed. On further Nitration 3-nitrobenzenesulfonic acid will be convert to 3,5-dinitrobenzenesulfonic acid because both Sulfonate and Nitrate groups are meta directing.