May 20, 2010, 1:46 PM
[CLOSED] HtmlEditor insertAtCursor bug on IE in 8.2 and 1.0
It appears that inserting text using the client side insertAtCursor function doesn't work properly in IE instead it inserts the text at the beginning of the string for IE. This function is working for FF and Opera when I tested, unfortunately the majority of the users on this particular product use IE. I would like to have this working in 8.2 at least initially. Please let me know if this can be fixed or if there is a valid work around like detecting IE and using the selection.getRange() on an object.
I'm using IE 8, please see the sample page below:
Switch out the ResourceManager with ScriptManager for testing on 8.2. the result is the same though.
I'm using IE 8, please see the sample page below:
Switch out the ResourceManager with ScriptManager for testing on 8.2. the result is the same though.
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="_Default" %>
<%@ Register Assembly="Ext.Net" Namespace="Ext.Net" TagPrefix="ext" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<title></title>
</head>
<body>
<form id="form1" runat="server">
<ext:ResourceManager ID="ResourceManager1" runat="server">
</ext:ResourceManager>
<table>
<tr>
<td>
Subject:
</td>
<td>
<ext:TextField runat="server" ID="EmailSubject" />
</td>
</tr>
<tr>
<td>
Tokens:
</td>
<td>
<ext:ComboBox Editable="false" runat="server" ID="EmailTokens">
<items>
<ext:ListItem Text="InsertValue" Value="InsertValue"/>
<ext:ListItem Text="InsertValue2" Value="InsertValue2"/>
</items>
<listeners><Select Handler="#{HtmlEditor1}.insertAtCursor(this.value);" /></listeners>
</ext:ComboBox>
</td>
</tr>
<tr>
<td colspan="2">
<ext:HtmlEditor ID="HtmlEditor1" AutoRender="true" AutoCreate="true" runat="server">
</ext:HtmlEditor>
</td>
</tr>
</table>
</form>
</body>
</html>