Textbox的浏览器问题 [英] Browser issues for Textbox

查看:88
本文介绍了Textbox的浏览器问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经为文本框编写了代码。

I have written code for text box.

document.getElementById("<%=txtother.ClientID %>").innerText = msg.other



工作正常的Internet Explorer。



对于chrome我已经改变了


It is working fine Internet explorer.

For chrome I have Changed

document.getElementById("<%=txtother.ClientID %>").text = msg.ther



但是在浏览器文本框中没有显示值。



如何解决这个问题..请帮我解决这个问题。


but in browser textbox value is not getting displayed.

How to solve this issue..Please help me to resolve this issue.

推荐答案

你好,



更改客户端java脚本代码,如下所示。对于textbox类型的输入元素,您应该使用value属性。

Hello,

Change the client side java script code as shown below. For an input element of type textbox you should be using value attribute.
document.getElementById("<%=txtother.ClientID %>").value= msg.other



如需更多帮助,请参阅 [^ ]。



问候,


For more help see this[^].

Regards,





使用这个

Hi
Use this


' #<%= txtother.ClientID%>')。val(msg.ther);
('#<%=txtother.ClientID %>').val(msg.ther);





你会在所有浏览器中获得..



Pramod.K



you will get in all browsers..

Pramod.K

这篇关于Textbox的浏览器问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆