SaaS CMS has officially launched! Learn more now.

IE8 Editor on page problem


We have a site running on CMS5 R2 SP2 and on a pgae we have implemented a property as an editor (EditMode=true).

But in IE8 Some of the functions won't work such as inserting an image (we only get an undefined javascript error) and none of the alt text on the toolbuttons is showing up.

We have the following code in OnInit

if (!Page.ClientScript.IsClientScriptIncludeRegistered("system.js"))
Page.ClientScript.RegisterClientScriptInclude("system.js", ((PageBase)Page).ResolveUrlFromUI("javascript/system.js"));
Page.ClientScript.RegisterClientScriptInclude("system.aspx", ((PageBase)Page).ResolveUrlFromUI("javascript/system.aspx"));
Page.ClientScript.RegisterClientScriptInclude("episerverscriptmanager.js", ((PageBase)Page).ResolveUrlFromUtil("javascript/EPiServerScriptManager.js"));
PropertyLongString longString = new PropertyLongString();
// select chosen options or use EditorToolOption.All            
longString.EditorToolOptions = EditorToolOption.All; 
longString.Name = "MailTemplateStringProperty";
MailTemplateEditor.InnerProperty = longString; 
Dec 08, 2009 8:42

Issue solved by EPiServer support.

The following was the issue:
If you inserted a new image in the editor everything works fine but if you selected the image again and pressed the image button tool in the editor you got a javascript error on page.

This only happens in IE 8 (not if you run in compability mode)

Change the following in the HyperlinkImageProperties.js located under EPiServer\CMS\5.2.375.236\application\util\Editor\javascript:

First is Line 262 if(!widthAttr.specified)
which should be if(widthAttr == null)

Second is 282 if(!heightAttr.specified)
which should be if(heightAttr == null)

Dec 11, 2009 15:53

The same lines of code needs to be fixed in HyperlinkProperties.js in order to get linking on images to work.

Nov 04, 2010 18:07
* 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.