function VisibleDiv(obj) {
if (obj == BaseLog) {
var objStyle = document.getElementById('DivCalls').style;
if (objStyle.display == "block")
objStyle.display = "none";
else
objStyle.display = "block";
}
else if (obj == ViewReports) {
var objStyle = document.getElementById('DivReports').style;
if (objStyle.display == "block")
objStyle.display = "none";
else
objStyle.display = "block";
}
else if (obj ==Management) {
var objStyle = document.getElementById('DivManage').style;
if (objStyle.display == "block")
objStyle.display = "none";
else
objStyle.display = "block";
}
<a href="#" id="BaseLog" class="TextHeader" onclick="VisibleDiv(this)">Base Log </a>
in the above code is working in IE but not working in mozilla 3.6.
I have checked that obj==BaseLog
is not working in the above code.
I have tried many options like
event.srcelement
window.event.srcelement
but all in vain.
when I debug the code ,I found that obj is having complete value for IE but
the same obj is having all the names .ie. the name of tag,id and class for "Base Log" seperated by #. i.e a#BaseLog#TextHeader#
Please suggest what shoud I do?