Senthil Nathan Posted December 4, 2006 Share Posted December 4, 2006 I have some problem to show the photo list using ajax. In this code is working fine in IE but the photo's not displayed in Firefox and Netscape browsers.The photo's are build in a table through php and assign the table of content to an div tag.This assignment working in IE but firefox and Netscape the divtag innerHTML content not shown.I try to find the solution about the problem. Not yet fixed problem.Any one pls help me to solve the problem..ThanksSenthil Nathan N.S Quote Link to comment https://forums.phpfreaks.com/topic/29388-hi-all/ Share on other sites More sharing options...
obsidian Posted December 4, 2006 Share Posted December 4, 2006 You'll need to show us some code to help us give you relevant solutions. The first thing you need to do is run some alerts or other tests to make sure that your HTTP requests are returning the values you think they are. Once you know that you are indeed getting the right values, we can help you make sure that your images are being created properly, and finally, that your HTML is properly being updated. Quote Link to comment https://forums.phpfreaks.com/topic/29388-hi-all/#findComment-134784 Share on other sites More sharing options...
Senthil Nathan Posted December 4, 2006 Author Share Posted December 4, 2006 I checked the table content using alert and it's building fine. But it is not shown in the innerHTML of the div tag. I'm also showing some other related content used in div tag. All are shown fine except the photo's builded table.The same codes are working fine in IE. But the photo display div tag only not working in Firefox and Netscape.I try to assing photo builded table content with some more strings, the strings only assigned in the div tag innerHTML but the table of photo's not shown.Please help me to solve the problem.Thanks Senthil Nathan N.S Quote Link to comment https://forums.phpfreaks.com/topic/29388-hi-all/#findComment-134793 Share on other sites More sharing options...
ober Posted December 4, 2006 Share Posted December 4, 2006 Show us your code where you create the xmlhttp object. $20 bucks says you're only using the ActiveX control. Quote Link to comment https://forums.phpfreaks.com/topic/29388-hi-all/#findComment-134797 Share on other sites More sharing options...
Senthil Nathan Posted December 4, 2006 Author Share Posted December 4, 2006 //#======================================= Ajax function starts here =================================== #// function createXMLHttpRequest() { var ua; if(window.XMLHttpRequest) { try { ua = new XMLHttpRequest(); if(ua.overrideMimeType) { ua.overrideMimeType('text/xml'); } } catch(e) { ua = false; } } else if(window.ActiveXObject) { try { ua = new ActiveXObject("Microsoft.XMLHTTP"); } catch(e) { ua = false; } } return ua; } var req = createXMLHttpRequest(); //#-- Function used to show the member album function funShowAlbum() { req.open('get','album_display.php',true); req.onreadystatechange = handleResponse; req.send(null); } //#-- end of function album display function handleResponse() { if(req.readyState == 4) { var response = req.responseText; var update = new Array(); if(response.indexOf('||' != -1)) { update = response.split('||'); document.getElementById("mainTable").style.display = "block"; if(update[1] != 'Error') { if((update[0] != 'undefined' && update[1] != 'undefined' && update[2] != 'undefined' && update[3] != 'undefined' && update[5] != 'undefined') || (update[0] != undefined && update[1] != undefined && update[2] != undefined && update[3] != undefined && update[5] != undefined)) { document.getElementById("memAlbumDisplay1").style.display = "block"; document.getElementById("memAlbumDisplay1").style.visibility = "visible"; document.getElementById("memAlbumDisplay1").innerHTML = update[0]; document.getElementById("memNext").innerHTML = update[5]; document.getElementById("memAlbumPaging").innerHTML = update[1]; document.getElementById("memAlbumSortList").innerHTML = update[2]; document.getElementById("memAlbumDetails").innerHTML = update[3]; response = undefined; } else { window.location.href = "album_display.php"; response = undefined; } } else { window.location.href = "upload_test.php"; response = undefined; } } } }//#======================================= End of Ajax function =================================== #// I have used the above ajax function to show the photo's and some other content.Go through the function and help me how to fix the problem.Thanks Senthil Nathan Quote Link to comment https://forums.phpfreaks.com/topic/29388-hi-all/#findComment-134808 Share on other sites More sharing options...
ober Posted December 4, 2006 Share Posted December 4, 2006 I don't see anything wrong with that at a quick glance... If you remove all the manipulation of the response, are you getting anything? Quote Link to comment https://forums.phpfreaks.com/topic/29388-hi-all/#findComment-134812 Share on other sites More sharing options...
senthilnathanns@yahoo.com Posted December 4, 2006 Share Posted December 4, 2006 I build the content in the php page using pipe symbol "||" for seperate the content. I had already used this symbol and it didnot affect the resultant of the ajax function.I have try to using innerContentText the photo table content has been build the div tag innerHTML content.But i have used to show the photo's in the div tag for innerHTML. i will try to trace where the problem arrives..If any idea to solve the problem is more help to meThanksSenthil Kumar N.S Quote Link to comment https://forums.phpfreaks.com/topic/29388-hi-all/#findComment-134831 Share on other sites More sharing options...
ober Posted December 4, 2006 Share Posted December 4, 2006 If you can post a link to the live version, that would help us. Quote Link to comment https://forums.phpfreaks.com/topic/29388-hi-all/#findComment-134898 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.