开发者

Span tag inside the asp text box is not working in Firefox

I am able to generate some tags inside the asp textbox control using jquery

Following is the jquery

var bb = document.createElement('span');
  开发者_StackOverflow中文版 bb.innerHTML= "test123";
   $("#" + "<%= TextBox1.ClientID %>").append(bb);

I can see the text "test123" in IE but a blank textbox in Firefox(I am using 5).

When I see in firebug, that span got create inside the textbox.

Can anyone tell me how to make that span content to be displayed/get shown in FF too?


I had encountered this problem before ::

Essentially .append operation is adding the span into . Changes to this are not always reflected in Chrome/Firefox .

Instead try adding it by using

TextBox.value += "Testing content addition";
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜