Take the 2-minute tour ×
SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. It's 100% free, no registration required.

I have created a custom master page for my site, but when i have set it as the sites master page the changes i have made to default.aspx no longer seem to be working.

I have changed the sites default.aspx page with a small bit of custom JavaScript, this works fine when using the v4.master, but as soon as i switch to the custom master page it stops working. Its as if its not using the default.aspx i have altered.

Any idea what could be causing this?

Cheers Luke

share|improve this question
    
What, exactly did you change via JavaScript? Where is that JavaScript loaded - the <head> tag in the MasterPage or somewhere in the default.aspx Page Layout? When I create a new MasterPage I generally begin by copying and pasting the entire contents of another MasterPage I know is working, and modify it to suit my needs. –  vynsane May 2 '13 at 2:24
add comment

3 Answers 3

Make sure that all the original placeholders are still available on the custom master page. If you want to remove some of them you should do it using css Style="display:none"

share|improve this answer
add comment

Selecting a different master page will not change which version of dafault.aspx is used.

But it could be that the changes in default.aspx is put into a Content control where the corresponding ContentPlaceHolder is in a non visible panel, which is a common way to get rid of unwanted ContentPlaceHolders (as you can't remove it without breaking pages).

Another problem could be that your custom master page doesn't include javascript libraries, the javascript in default.aspx depends on. Or include javascript which replaces the javascipt in default.aspx.

Finally it could be that your javascript tries to change something which isn't on the page any more.

But all in all it's very hard to diagnose without knowning the javascript or the changes to the master page

share|improve this answer
    
thanks ill have a poke around the code to see if i have missed anything –  beakersoft May 1 '12 at 13:11
    
If you get stuck then add the javascript and changed master page to the question –  Per Jakobsen May 1 '12 at 13:20
add comment

The custom master pages in 2010 are considerably different than they were in 2007 and there are a lot of ways to make mistakes when creating your own. I would strongly advise comparing your custom page to the blank and very well documented Starter MasterPage on CodePlex. Be especially on the lookout for missing/hidden contentplaceholders and server controls that appear in the Starter page but not in your custom master.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.