Page 1 of 1

Remove hyperlink from edit column

Posted: 23 Feb 2017
by jpwallace
I have the following code placed in the javascript editor on my display form to remove hyperlinks from lookup columns, when i put the same code in my edit form, the layout of the form changes (i lose my tabbed related items) and am still able to click lookup columns, what should i change in order to have this work on my edit form.

Code: Select all

$(document).ready(function() {
$('a[href*="RootFolder=*"]').each(function(index) {
var link = $(this);
$(this).after("<span>" + link.text() + "</span>");
$(this).remove();
});
});

Re: Remove hyperlink from edit column

Posted: 27 Feb 2017
by Dmitry Kozlov
Hi,

Most likely, you have a syntax error in your edit form. Expand the browser console (F12) and check the error messages.

Re: Remove hyperlink from edit column

Posted: 11 Apr 2017
by jpwallace
Hi Dmitry,
I have checked for errors and one syntax error is appearing. Its an unrecognized expression: a[href*=RootFolder=*"]............what should I replace this with?

Re: Remove hyperlink from edit column

Posted: 11 Apr 2017
by Dmitry Kozlov
Click the error in the console, most likely you just missed a quote somewhere.