Have a list with a lot of columns that extends off the side of the page and looks rather odd? We have a nice fix for that. Here's what needs to be done:
- Navigate to a list which extends off the side of the page
- Select the Edit page option from the SharePoint ribbon or SharePoint Setting gear.
- When the page is in edit more, select Add a Web Part.
- Add a Script Editor web part from the "Media and Content" category.
- With the Script Editor web part on the page, select the Edit Web Part option from the web part menu.
- Scroll to the web parts tool pane, expand open the Layout section, select the Hidden option, and the click the OK button. This is required to keep the Script Editor web part from interfering with the position of other items on the page.
- Now select the EDIT SNIPPET link on the script editor web part.
- Copy and paste the supplied code (located at the end of this article) into the text area of the Embed modal the opens and select "Insert"
- Select the Stop Editing option from the SharePoint ribbon
- That's it! The page body background will now extend the fill width of the list.
Here's the Embed code: