getting the right links to show