Save Button Missing

Jun 4, 2015 at 10:35 PM
I am having an intermittent problem where the save button goes missing from the settings area. The Cancel, Remove, and Replace with other Content buttons are visible but the Save button is missing. This is happening with user accounts that have previously been able to use these options. The user has the 2SexyContent Designers group set.

If I view the source of the page by inspecting the element, I can see where the style of the save button has been set to "display:none;". This is what is causing the button to hide, but I don't know why it is hiding.

I use many different templates in the 2sxc and this is only happening with some of them. Is there a setting that could be causing this?
Jun 5, 2015 at 6:57 AM
Save is disabled until all JavaScript has been parsed successfully. So if save is missing, something doesn't initialize properly. Check what's happening at JS level.
Jun 5, 2015 at 5:07 PM
Thanks for helping. I appreciate the info and am looking into JavaScript. Although I am looking at the JS, in this particular case, I think I may be running into something a little bit different.

If the JavaScript parsing were the issue, wouldn't it affect all users? In my case, I had an account that was able to edit the settings and save that at some point became unable to do so. My SuperUser account also does not see the Save Button. I added a new account with roles that match the account I typically use to edit. The new account can see the Save Button where the old account that basically matches and my SuperUser do not. I would think a JS issue would affect all of these users. This point is confusing me. Why does adding a new account with the same permissions allow the Save Button to become visible?

I also tested removing all roles from the old account and reassigning them. This did not cause the Save Button to appear. Note that the user is able to use save for some of the Content Modules on the page, so permissions don't seem to be the main factor.

As stated above, this only affects certain templates. There can be multiple Content modules on the page, some are able to save and some are not. The ones that are unable to save do not have any JS in the templates themselves. Wouldn't a JS parsing issue affect all the Content modules on the page?

The skin I use on the page also does not have any custom JavaScript. There is JS that is added by DNN when I view the source. Is there any way to prevent DNN from wrapping the skin with all extras?
Jun 5, 2015 at 6:05 PM
That was good info. Further inspection shows that you were onto something. I took a look in the Console tab of the Chrome browser and saw that there is indeed a JS error. The JS error only occurs for the affected accounts so that would explain what I was seeing.

The JS error is, "Uncaught TypeError: Cannot read property 'id' of undefined".
This is happening in the JavaScript produced by DependencyHandler.axd. Line 587 if that matters. I think this is JS that is dynamically created. Does that error message give us a clue?
Is there some property in the user account that needs to be updated?

Thanks again.
Jun 5, 2015 at 6:47 PM
I believe this is where the JavaScript error is happening:
var editor=$find(objWrapper.find(".RadEditor").get(0).id);
Jun 6, 2015 at 6:59 AM
I was guessing something like that. I can't say what it is, but apparently something is different with the RAD editor if this user is accessing it. Some guesses

Maybe the user doesn't explicitly have permissions to read something (like the content-folder) - causing the rad-editor to not load fully...

or you have custom configuration for the toolbar in the WYSIWYG for this user-group - and the configuration is messed up.

I would test
  1. Does the error only occur, when the dialog has WYSIWYG (just to be sure it's related to that)
  2. do you have custom toolbar-configurations for the wysiwyg?
  3. do you have custom file permsissions (or not set yet) - this sometimes has funny side-effects