Ensure generated link headers include an anchor parameter as needed

Fixes https://www.pivotaltracker.com/story/show/81018546