fix servlet xhr url computation