Jump to:

5513 Posts in 1732 Topics by 1218 members

Customising the CMS

SilverStripe Forums » Customising the CMS » In Live mode, CMS hangs on loading and spits out JS errors

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba, simon_w

Page: 1
Go to End
Author Topic: 688 Views
  • Ryan M.
    Avatar
    Community Member
    309 Posts

    In Live mode, CMS hangs on loading and spits out JS errors Link to this post

    When I put my site into Live mode and load the CMS at /admin, it hangs with the "loading..." text staying there and my Firebug lists some javascript related errors. If I put my site into Dev mode, I'm able to access the admin area just fine.

    Any hints??

    Attached Files
  • Willr
    Avatar
    Forum Moderator
    5482 Posts

    Re: In Live mode, CMS hangs on loading and spits out JS errors Link to this post

    The main difference between dev/live for the admin section would be the automatic minification of files. You can see if disabling that helps:

    Requirements::set_combined_files_enabled(false);

  • Ryan M.
    Avatar
    Community Member
    309 Posts

    Re: In Live mode, CMS hangs on loading and spits out JS errors Link to this post

    That fixed it!
    I would like to fix the underlying problem though so that users don't have to implement this solution to get the admin to work.

  • Willr
    Avatar
    Forum Moderator
    5482 Posts

    Re: In Live mode, CMS hangs on loading and spits out JS errors Link to this post

    Well the underlying issue is that in your case the js isn't being minified in the correct way. Have you made any modifications to the CMS? new javascript, using DOM or any modules..

    Take out that line I mentioned and look at the contents of the generated minified file (assets/_combined_files/leftandmain.js) and check that it contains content.

  • Ryan M.
    Avatar
    Community Member
    309 Posts

    Re: In Live mode, CMS hangs on loading and spits out JS errors Link to this post

    The only modules I have installed are: DOM, UserDefinedForms, Uploadify plus the standard SS installation.
    I don't have any custom JS in the CMS. Just using some DOM and HasManyComplexTableField instances here and there.

    Some more insight... I removed the line like you suggested and reloaded the CMS. Surprise, no problem this time. However I was logged in already.. maybe this issue only surfaces when you're logging in. Also, I didn't see an assets/_combined_files/ folder... this tells me it's probably not being generated.

  • Willr
    Avatar
    Forum Moderator
    5482 Posts

    Re: In Live mode, CMS hangs on loading and spits out JS errors Link to this post

    You won't see the folder via the cms, but you should see it in the file system. If it's not on the filesystem check your admin permissions - make sure your web user can write to the folder. i.e http://www.silverstripe.org/assets/_combinedfiles/leftandmain.js

  • Ryan M.
    Avatar
    Community Member
    309 Posts

    Re: In Live mode, CMS hangs on loading and spits out JS errors Link to this post

    Yeah I was looking in the file system to begin with.
    I set the assets folder perms to 777 and still don't see the _combinedfiles folder. Perhaps I need to create it and set perms on it first?
    Another insight... I don't get hit with the loading hang anymore, even when I log out and then back into the admin.

    688 Views
Page: 1
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.