Monday, July 10, 2006

Best practices for editing master pages

I saw Shane's article about Customizing Master Pages using SharePoint Designer 2007, where he warns about frontpage changing the referances automatically, and I thought I should write some best practices as I find them (will be updated in the future).

Best practices:

  1. Only change a master page after you backed it up.
  2. If you are changing a master page in a site and not the global one, don't back up using frontpage copy and rename (see Shane's article). Instead, download the master page to your computer and save it in a folder with a note to what site it belongs to.
  3. Back up the entire "12" directory before you do anything on a sharepoint server local files. To make my self clear, I am talking about "c:/program files/common files/microsoft shared/web server extensions/12" folder.
  4. Editing master pages in frontpage (aka sharepoint designer) is not recommended (by me) since it tries to update the links to the controls, and then you get in trouble. What fronpage does is remove the "~" character before the link to the controls in the ">%@ Register" section at the top of the page. If you must edit the file using frontpage, you should open it again in notepad and add the "~" charecter in the register tag, before the "/_controltemplates" link. An easy way to do it, is open the file in notepad, and do a search for "/_controltemplates and replace with "~/_controltemplates

Again I'd like to stress that these 4 rules are just the begining. We will have a lot more, so keep in touch - I will update when I learn more.

If you liked this article, please kick it!
kick it on


Anonymous said...

Dude, you have GOT to stop calling SharePoint Designer FrontPage. SPD is so far beyond FP it's not even funny. As a fellow MVP, you have to get your terminology right. Reading your post, people might think they could use FP to edit MOSS sites which is SO not recommended!


Anonymous said...

Dude, SharePoint designer is "Frontpage on steroids"

< G >