add/remove links, JSON tidy-up, show/hide links