Hide columns on NewForm, DispForm, EditForm in SharePoint list
To add web parts to any page within Sharepoint:
On the URL of the form page you are, add to the end of it: &toolpaneview=2 (i.e. Or remove all the stuff (querystring) stuff at the end of URL and change it to DispForm.aspx?toolpaneview=2. The page will then change to Edit Mode:
From here, add a CEWP, content editor web part, to the page UNDER the form already on the page. This is very important, if will not work if the CEWP is not under the form. Modify the CEWP, open the source editor, and paste in:
<script type="text/javascript"> var containers = document.getElementsByTagName("*"); for (var i=0;i<containers.length;i++) { if (containers[i].innerText == 'Recurrence' || containers[i].innerText == 'Workspace') { if(containers[i].tagName == 'H3') { containers[i].parentNode.parentNode.style.display = 'none'; } if(containers[i].tagName == 'NOBR') { containers[i].parentNode.parentNode.parentNode.style.display = 'none'; } } } </script>Save and close it. Now, the columns should be gone! Another quick tip, if you need to hide any other columns, in the code above find the section:
containers[i].innerText == 'Recurrence' || containers[i].innerText == 'Workspace'For each column you need to hide, append it like this:
containers[i].innerText == 'Recurrence' || containers[i].innerText == 'Workspace' || containers[i].innerText == 'Title'The code above will also hide the Title column. If you want to hide just one, remove the pipe characters ( || ) around each statement and remove all but the one you need:
containers[i].innerText == 'Location'
adapted from Kevin's post here.