Posts

Showing posts from September, 2010

sharepoint trick to edit "new item form" by adding to url

Image
Hide columns on NewForm, DispForm, EditForm in SharePoint list To remove columns from appearing on a display, edit item, and new item form in SharePoint lists, e.g.: The goal is to add some JavaScript into a Content Editor Web Part (CEWP) on the above page. 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 == ...