SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am running into a strange problem that SP.Ribbon.js is not getting loaded.

Normally if I view page source, there will be a bunch of RegisterSod(...) lines that loads a bunch of sharepoint javascript files on demand, including SP.Ribbon.js. However most of the other RegisterSod lines are still there (like for sp.core.js, sp.runtime.js, etc), but the one loads sp.ribbon.js disappeared.

Our custom master page could be a possible problem, but it works in 3 out of 5 environments, so I'm thinking it has more to do with configuration or other environmental problems. But I have no idea where to look, and no idea where is the corresponding code for those core SP script files.

I hope the above makes sense, and any help will be much appreciated!

Update: In the broken environments, if I change the web's UIVersion to 4 (it was changed to 3), the missing js files (cui.js/sp.ribbon.js) will be loaded. This would not be the optimal solution however, as it breaks a lot of the html and css layouts.

Plus, UIVersion being 3 does not seem to cause those js files to be missing in other environments, only if I can figure out why...

share|improve this question

Did you try to retrieve the file on the server(s) suffering from that issue ? A direct call to the js file from the /_layouts/ path would ensure that

  1. the file exists
  2. the permission on the IIS are still ok

You could run the Configuration Wizard on these server as they will try to fix (or fail and tell you why) the 14 directory (mostly permission issue since a deleted file can't be retrieve that way).

Fire up the IE Dev toolbar and under the network tab, check if you have a request to that file, and if you receive a 404 / 401 /

share|improve this answer
Just tried it, both cui.js and sp.ribbon.js are accessible. I think the problem I have is that those files are not even registered in ScriptManager (wish I knew where and the condition they are registered) so the page doesn't even try to load those files. – Bill Yang Jan 29 '13 at 20:59
did you try with a vanilla v4 master page ? – Francois Verbeeck Jan 29 '13 at 21:17
It seems with vanilla site, both the default v3 and v4 master page would load cui.js and sp.ribbon.js, but there is no code to explicitly registers those files to ScriptManager in vanilla master pages. – Bill Yang Jan 29 '13 at 21:30

Your Answer


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.