open sharepoint attachment in browser new window

To open sharepoint attachment in browser new window. here is the code $(document).ready(function() { $.each($("a[onclick*='DispDocItemExWithServerRedirect']"), function(i, anchor) { var attUrl = $(this).attr("href"); $(this).removeAttr("onclick"); $(this).removeAttr("onmousedown"); $(this).click(function (){ window.open(attUrl); return false;}); }); });

Comments

AlexanderK79 said…
Where do I put this code on my form to have it activated?

Popular posts from this blog

WCF interview questions

The term 'Connect-MsolService' is not recognized as the name of a cmdlet, function, script file, or operable program

what is Event Cache table in sharepoint