innerHTML is working Fine FF and not in IE 6.0 version

They have: 1 posts

Joined: Dec 2010

this.componentHtml = function _componentHtml() {

var htmlStr = '';
htmlStr += ''
+''
//+'Enter Team Details'
+ '';
/*+'Team Name '
+''
+''
+'  '
+'Team Id '
+''
+''
+'  '
+'  '
+' ';*/
htmlStr += '';
htmlStr += ''
+''
+''
+''
+'';

return htmlStr;

}

function validTeamData(pTeamName,teamId){
if((pTeamName==""||pTeamName.length==0)|| (teamId=="" || teamId.length==0)){
alert("Fields can not be empty. Please enter correct details.");
return false;
}
return true;
}

function callTeamLeadManagerMachine(request,uri,callBack){
isState = false;
xmlHttp=GetXmlHttpObject();
if (xmlHttp==null){
alert ("Browser does not support HTTP Request")
return
}
//var url=uri;
xmlHttp.onreadystatechange = callBack;
xmlHttp.open("POST",uri,true);
xmlHttp.send(XML.toString(request));
}

function GetXmlHttpObject(){
var objXMLHttp=null
if (window.XMLHttpRequest){
objXMLHttp=new XMLHttpRequest()
}else if (window.ActiveXObject){
objXMLHttp=new ActiveXObject("Microsoft.XMLHTTP")
}
return objXMLHttp
}

function stateChanged(){
if(xmlHttp.readyState==4 || xmlHttp.readyState=="complete"){
document.getElementById("animIcon").innerHTML = '';
var lResponseData = XML.parse(xmlHttp.responseText);
if (lResponseData == null) {
alert("No Response from the server.");
return ;
}

var lResponseMsg = XML.selectOne(lResponseData,"response");
if(lResponseMsg == null){
alert("Empty Response from the server.");
return ;
}

var lUsersData = XML.selectOne(lResponseMsg,"users");
if(lUsersData == null || lUsersData==''){
alert(XML.getText(lResponseData,"message"));
return ;
}

var lUsersList = XML.select(lUsersData,"user");
document.getElementById("controlDiv").innerHTML = '';
var lHtmlString = 'Team Users Details ';

// var lHtmlString = ''
// +''
// +'Team Users ';

var lString='';
var lUserName='';
var lUserId='';
var status ='';
for(var i=0; i'
+'' ;
lString +=''+lUserName+''+status+'';
}

lHtmlString+=' &nbspUser NameStatus';
lHtmlString+=lString;
lHtmlString+= ''

+''
+'close'
+'suspend'
+''
+''
+'';
lHtmlString+='';
document.getElementById("controlDiv").innerHTML =lHtmlString;
}else{
document.getElementById("animIcon").innerHTML = 'Plz wait as report is processing..!';
}
}

function cmsCallBack(){
if(xmlHttp.readyState==4 || xmlHttp.readyState=="complete"){
var lResponseData = XML.parse(xmlHttp.responseText);
if (lResponseData == null) {
alert("No Response from the server.");
return ;
}
var response = XML.selectOne(lResponseData,"response");
alert(XML.getText(lResponseData,"message"));
var lTeamLeadManagerRequest =MBFactory.getCMSRequestTemplate("get",MB.getTeamFrame().TEAM.lookUpToken().split("-")[0]);
XML.setText(lTeamLeadManagerRequest,"team-id",MB.getTeamFrame().TEAM.lookUpToken().split("-")[1]);
callTeamLeadManagerMachine(lTeamLeadManagerRequest,lCMSURL,stateChanged);
}
}

this.handleClick = function _handleClick(pElement,pExtras) {
switch(pElement.name){
case 'getUsers' :{
var lTeamName = document.getElementById("teamName").value;
this.teamName= lTeamName;
this.teamId = document.getElementById("teamId").value;
if(validTeamData(lTeamName,this.teamId)){
var lTeamLeadManagerRequest = MBFactory.getCMSRequestTemplate("get",this.teamName);
XML.setText(lTeamLeadManagerRequest,"team-id",this.teamId);
callTeamLeadManagerMachine(lTeamLeadManagerRequest,lCMSURL,stateChanged);
}
return true ;
}

case 'update' :{

if(this.checkedUserIds.length==0){
alert("please select user") ;
return false;
}else {
var lStatus = document.forms["suspend"]["status"].options[document.forms["suspend"]["status"].selectedIndex].text;
var lRequest = MBFactory.getCMSRequestTemplate("suspend",MB.getTeamFrame().TEAM.lookUpToken().split("-")[0],this.checkedUserIds.toString(),lStatus,MB.getTeamFrame().TEAM.lookUpToken().split("-")[1]);
callTeamLeadManagerMachine(lRequest,lCMSURL,cmsCallBack);

for(var i=0;i

She has: 44 posts

Joined: Dec 2010

Make sure you have added the code in an external JS file.

Greg K's picture

He has: 2,145 posts

Joined: Nov 2003

How about giving stripping down the code to what you feel isn't working and just posting that part (or give a url to a sample page that is not working). Trying to read though badly formatted/ha;f commented out code makes it too much of a pain to try to diagnose for me.

He has: 10 posts

Joined: Jan 2011

Quote:
How about giving stripping down the code to what you feel isn't working and just posting that part (or give a url to a sample page that is not working). Trying to read though badly formatted/ha;f commented out code makes it too much of a pain to try to diagnose for me..

Hi,

I agree with Greg, Kindly provide just link of the error page. We will solve it.

Want to join the discussion? Create an account or log in if you already have one. Joining is fast, free and painless! We’ll even whisk you back here when you’ve finished.