js works for when there are 3 urls needs work