One of the attacks was on an election rally where President Ashraf Ghani was due to speak.