I have a standard SharePoint Links List with entries for each of our file servers as
file:////filesharename
which opens the file share with no problems. The problem I am seeing with this configuration is each time a user clicks on the link, the page with the Links List goes blank. If you click the back button on the browser the screen appears normal.
is there a setting or script that I can utilize to open the links without blanking out the page?
Edit: Here is the solution for opening the links in a new window. I would like to thank SharePoint Lessons Learned for the blog post
<script language="JavaScript">
_spBodyOnLoadFunctionNames.push("rewriteLinks");
function rewriteLinks() {
//create an array to store all
var anchors = document.getElementsByTagName("a");
//loop through the array
for (var x=0; x<anchors.length; x++) {
//check to see if the current anchor element contain #openinnewwindow
if (anchors[x].outerHTML.indexOf('#openinnewwindow')>0) {
//add the [target] attribute and rewrite the [href] attribute
anchors[x].target = "_blank";
anchors[x].href = anchors[x].href.replace(/#openinnewwindow/,'');
}
}
}
</script>