adapted docserve for new target handling, may now return multiple elements to
be updated