Sharepoint’s wiki implementation is rudimentary, but still useful. One of the corners cut in the implementation is that incoming links are on a separate page – you have to click the Incoming Links link (and wait for the screen to refresh) to see them. It’d be much more user-friendly to show these links on the same page as the content.
Turns out with jQuery this is a fairly trivial exercise, at least for a single Wiki page*: Simply add a Content Editor Web part to the page and copy the following code into the Source Editor.
It may be noted that the above code could even be combined into one single chain – I prefer the above for readability and debugging purposes. Also not sure if I need to dispose of the local variables – this is a POC more than anything else.
The incoming links are now on the page, right below the content:
A more thorough implementation might position the links in a box in the upper left corner, and simultaneously removing the “Incoming Links” link.
*I haven’t quite thought out how to inject this throughout a wiki. Any suggestions?