improve header view to handle all links with one function.