Quantcast
Channel: AjaxControlToolkit Work Item Rss Feed
Viewing all articles
Browse latest Browse all 4356

Commented Issue: custom MasterPage ID breaks HtmlEditorExtender [27157]

$
0
0
(Using MAY 2012 ASP.NET 3.5 AJAX Toolkit release, IE7) When using a MasterPage, if you set the ID then the HtmlEditorExtender "popupDiv" always displays.

Ex:

on MasterPage codebehind:
protected void Page_Init(object sender, EventArgs e)
{
this.ID = "TEST"; // comment this out, the HtmlEditorExtender works properly
}

on Default.aspx - have the textbox and HtmlEditorExtender inside the ContentPlaceHolder

========== UPDATE

I forgot to mention, the reason for this appears to be because the "popupDiv" does not update with the new MasterPage ID, but the other elements do.

Using the MasterPage, setting this.ID = "TEST" on Page_Init

Default.aspx page referencing MasterPage:
<asp:Content ID="Content2" runat="server" ContentPlaceHolderID="cphContent">
<asp:TextBox ID="TextBox1" runat="server" TextMode="MultiLine" Rows="10" />
<AjaxControlToolkit:HtmlEditorExtender ID="HtmlEditorExtender1" runat="server" TargetControlID="TextBox1" />
</asp:Content>

renders as:

<textarea name="TEST$cphContent$TextBox1" rows="10" cols="20" id="TEST_cphContent_TextBox1"></textarea>
<input type="hidden" name="TEST$cphContent$HtmlEditorExtender1_ClientState" id="TEST_cphContent_HtmlEditorExtender1_ClientState" /><div Id="ctl00_cphContent_HtmlEditorExtender1_popupDiv" style="opacity: 0;" class="popupDiv"><div Id="ctl00_cphContent_HtmlEditorExtender1_btnCancel" style="float: right; position:relative; padding-left: 20px; top:10px; width: 55px; border-color:black;border-style: solid; border-width: 1px;cursor:pointer;" float="right" unselectable="on">Cancel</div></div>


As you can see, the popupDiv and btnCancel div both say "ctl00" instead of "TEST"... I'm thinking this has something to do with why this displays when you modify the MasterPage ID...
Comments: More clarification: this only appears to be a problem when using an older browser (IE8) or compatibility view.

Viewing all articles
Browse latest Browse all 4356

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>