本文介绍了如何使用javascript更改客户端标签的单词?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

hi
我在onclienclick clien端点击事件中遇到了Mozilla firefox的问题

(即OnClientClick =返回AddDevice_ClientClick())



我调用函数



hi I have a problem with Mozilla firefox in onclienclick clien side click event
( i.e OnClientClick="return AddDevice_ClientClick()")

I call the function

AddDevice_ClientClick()
{
           document.getElementById("ctl00_ContentPlaceHolder1_lblmftop").innerText = "Add Device";
           document.getElementById("ctl00_ContentPlaceHolder1_lblmfptop").style.display ="inline";
 return false;
}





页面加载lblmfptop是display = none,在客户端点击事件中我必须显示=内联和在我写的另一个单词(即.innerText =添加设备)的文本都在客户端。这将在IE和Chrome中工作,但在火狐中它不起作用。请回复asap



Thanx

Aravind



in page load lblmfptop is display=none ,in client side click event i have to dispaly=inline and in that text i write another word(i.e .innerText="Add Device") all are in client side.this will work in IE and chrome but in fire fox it not work. pls reply asap

Thanx
Aravind

推荐答案

if(document.all)
{
     document.getElementById('element').innerText = "my text";
} else{
    document.getElementById('element').textContent = "my text";
}


AddDevice_ClientClick()
{



这篇关于如何使用javascript更改客户端标签的单词?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

08-20 07:21
查看更多