update alt and title attributes