A critical vulnerability was discovered in React Server Components (Next.js). Our systems remain protected but we advise to update packages to newest version. Learn More

Issue with File Management link in EPiServer Admin Mode

Vote:
 

Hi,

When click on File Managment link in EPiServer CMS Admin mode, i am getting the following javascript exceptions.

Unterminated string constant - FileManagement.aspx

'SetupContextMenuHandler' is undefined - FileManagement.aspx

Also, the File management window shows the below junk lines of javascript code, Please help in resolving this issue.

Path: Documents
  ' ); wdoc.close(); } function handleDrag(e) { // Event handler for drag start of file. // Part of drag from file manager and drop into XHTML Editor. var dhtmlPath = GetSourceLink(e).getAttribute("dhtmlPath"); if(dhtmlPath!=null) { if (e._event){ // IE e._event.dataTransfer.effectAllowed = "copy"; e._event.dataTransfer.setData("Text", dhtmlPath); } else { // Other browsers // Don't set effectAllowed since drop targets in Firefox on mac needs to specify // same dropEffect in dragover event and we want to be able to drop in input fields without registering this event. e.dataTransfer.setData("Text", dhtmlPath); } e.stopPropagation(); return true; } } function SetupContextMenuHandler(e) { if (document.getElementById("browserCell") != null) { EPi.AddEventListener(document.getElementById("browserCell"), "contextmenu", handleContextMenu); } } function handleContextMenu(e) { //we want context menu to appear when user clicked in browseArea (definied in Browse.acx) or below it var browseArea = document.getElementById("browseArea"); if (browseArea != null) { var offSetArray = getOffSet(browseArea); if (e.clientY >= offSetArray[0]) { handleItemClick(e,true); } } } function getOffSet(element) { var curtop = element.offsetTop; var curLeft = element.offsetLeft; while (element = element.offsetParent) { curtop += element.offsetTop; curLeft += element.offsetLeft; } return [curtop, curLeft]; } function handleClick(e) { var srcElement = e.target; if(srcElement.getAttribute('IsToolEnabled')=='true') return; handleItemClick(e,false); } function handleItemClick(e,viewContextMenu) { var sourceElement = GetSourceLink(e); var dhtmlType = sourceElement.getAttribute('dhtmlType'); var isFavorite = sourceElement.getAttribute('isFavorite'); if(dhtmlType!=null) { //element is rendered from DragAndDropLinkButton which adds an attribute entryName with the value of Text var fileSystemObject = new FileSystemObject(sourceElement.getAttribute('dhtmlPath'), sourceElement.getAttribute('entryName')); if(!isSelected(fileSystemObject.path,dhtmlType)) { if(viewContextMenu || !e.ctrlKey) { ClearSelectedItems(); } handleSelection(e,fileSystemObject,dhtmlType); } else { if (!viewContextMenu) { if(!e.ctrlKey) { ClearSelectedItems(); } handleSelection(e,fileSystemObject,dhtmlType); } } } else if(viewContextMenu) ClearSelectedItems(); window.IsMultiSelection = (selectedFilesArray.length + selectedDirectoriesArray.length) > 1; window.IsMultiFileSelection = selectedFilesArray.length > 1; window.IsFileSelection = (selectedFilesArray.length == 1) && !window.IsMultiSelection; window.IsDirectorySelection = (selectedDirectoriesArray.length == 1) && !window.IsMultiSelection; window.IsAnySelection = (selectedFilesArray.length + selectedDirectoriesArray.length) > 0; window.IsFavoriteSelection = isFavorite != null && isFavorite == "true"; UpdateCommandTools(); if(viewContextMenu) { ContextMenu_557f2594_feff_4941_b24e_6ef62f50c76b.Show(e); } } function UpdateCommandTools() { var oDeleteButton = document.getElementById....

Thanks in advance.

Regards,

Saran

#73840
Aug 12, 2013 18:38
Vote:
 

Dear All,

       The issue has been resolved by uninstalling a new performance monitoring tool from the server. After uninstalling the tool, the File Management window got worked as before.

Thanks.


Regards

Saran

#74036
Aug 19, 2013 11:48
Vote:
 

We are having the same problem. What exactly was the performance monitoring tool?

#76918
Nov 06, 2013 12:18
Vote:
 

I've had similar problems with New Relic. There's a hotfix available from EPiServer support that fixes this.

Frederik

#77014
Nov 06, 2013 14:25
Vote:
 

Ah, here is the fix apparently....

 

Here is the fix for this:

Open DhtmlSupport.aspx in C:\Program Files (x86)\EPiServer\CMS\6.1.379.0\Application\UI\CMS\Hosting

 

Change:

wdoc.write( '</head><body></body>' );

 

To:

wdoc.write( '</he'+'ad><bo'+'dy></bo'+'dy>' );

 

please reset iis and delete ASP.net temp folder after changing.

 

Best regards,

EPiServer Developer Support 

#77023
Nov 06, 2013 16:04
This thread is locked and should be used for reference only. Please use the Episerver CMS 7 and earlier versions forum to open new discussions.
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.