473,839 Members | 1,361 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Firefox - 'undefined' error

20 New Member
I have a page with table layout which has an AJAX request sent on body onLoad event, during this time the table cells show static text like "Loading". The table cells are later updated with the AJAX response. So when I try to move out of the page once the AJAX request is sent by clicking on a link for exmple, the "Loading" changes to "undefined" . I read that innerHTML is not supported by firefox for table cells so i started using div inside the table cell yet no result. However IE and Opera seems to work fine. could anyone please tell me where am going wrong ?? Thanks a ton
May 7 '08 #1
23 2870
acoder
16,027 Recognized Expert Moderator MVP
Post your code so we can see where the problem might lie.
May 7 '08 #2
pravinasp
20 New Member
Thanks for your reply, The ajaxrequest is triggered by the following functions

Expand|Select|Wrap|Line Numbers
  1. function getReportStatus(geturl)
  2. {
  3.    var columnvals;
  4.    var filtervals;
  5.    url = geturl;
  6.    xmlObj = null;
  7.    xmlObj = GetXmlObj(); 
  8. // This function is to choose the right xmlhttp object according to the browser
  9.    xmlObj.onreadystatechange=stateChanged;
  10.    xmlObj.open("GET", url , true);
  11.    xmlObj.send(null);
  12.  
  13. }
  14.  
  15. function stateChanged()
  16.  {
  17.      if (xmlObj.readyState==4 || xmlObj.readyState=="complete")
  18.      {
  19.          data = xmlObj.responseText;
  20.          var data_split = data.split("|");
  21.  
  22.           document.getElementById("citystate").innerHTML= data_split[0];
  23.           document.getElementById("progress").innerHTML = data_split[1];
  24.           document.getElementById("function").innerHTML= data_split[2];
  25.  
  26.          // All the ids above are div element ids which are inside individual <td> elements
  27.  
  28.      }
  29. /*
  30.      else if(xmlObj.readyState==1)
  31.      {
  32.         document.getElementById("citystate").innerHTML = "HEY";
  33.         document.getElementById("progress").innerHTML = "Loading";
  34.         document.getElementById("function").innerHTML = "Loading";
  35.      }
  36.      else if(xmlObj.readyState==3)
  37.      {
  38.         document.getElementById("citystate").innerHTML = "HEY";
  39.         document.getElementById("progress").innerHTML = "Loading";
  40.         document.getElementById("function").innerHTML = "Loading";
  41.      }
  42. */
  43.   }
  44.  
Please let me know if you need any other piece of code as well.


Cheers
May 7 '08 #3
acoder
16,027 Recognized Expert Moderator MVP
I'll also need to see the relevant HTML code. If the code is too much and you have a test site link, post that instead.
May 7 '08 #4
pravinasp
20 New Member
Is it possible i can email you my test site?? I dont want it to be public

Thanks again

I'll also need to see the relevant HTML code. If the code is too much and you have a test site link, post that instead.
May 7 '08 #5
acoder
16,027 Recognized Expert Moderator MVP
PM me instead.
May 7 '08 #6
acoder
16,027 Recognized Expert Moderator MVP
I've had a look, but I am unable to reproduce the problem.

Can you give me some exact steps to trigger the error.
May 7 '08 #7
pravinasp
20 New Member
once you click the button 'Create Report' you will be inside the report center. Once you are are inside the report center, click on any link just to navigate away from the page. When you click on the link the the table cells which were saying 'Loading' would disappear and you will see 'undefined' appearing in those cells for a very brief time before you end up in the next page.Please let me know if you were able to reproduce it this time. Thanks for your efforts again.
May 7 '08 #8
pravinasp
20 New Member
hey were you able to reproduce error now??
May 8 '08 #9
acoder
16,027 Recognized Expert Moderator MVP
Yes, it seems it's only triggered if you leave the page.

I'm not sure what might be triggering it, but perhaps you need to abort the request onunload.
May 8 '08 #10

Sign in to post your reply or Sign up for a free account.

Similar topics

2
4723
by: Johnny | last post by:
Searched on google for any info relating to this before posting here but found none. I set up a web service using nusoap on apache php 4.3.8 on windows with error_reporting = E_ALL and had that service set a cookie in the client browser as the first output. Works fine in IE6 and the service returns the state of the cookie in the client browser but in firefox 1.0 the exact same service gives a notice error about an undefined variable...
4
9308
by: Stuart Perryman | last post by:
Hi, I have the following code which works just fine in IE6 but not in Firefox. It is an extract of several table rows each with an individual form. It is generated by php. <form action="MaintNotification.php?ReqID=5" method="post" name="frm5"> <tr align="left" bgcolor="#dddddd" class="text" onClick="submit()"
15
19894
by: Dan | last post by:
Hi. I've got the following line of code which works fine in IE ... line_1_numbers = document.getElementsByTagName ('table').rows (0).cells (0).innerText; But it Firefox, it barks saying: "Error: document.getElementsByTagName("table").rows is not a function"
5
3515
by: Martin Chen | last post by:
I have a frame set (as per MS FrontPage 2000). It has a contents and a main frame. The contents frame has a menu bar written with with javascript (in the context of a table). In IE6.1 everything works fine as it also does in firefox if I call the contents frame directly (i.e. outside of its frameset). However, if I call my main page (index.html) which invokes the frame set, the contents frame javascript menubar onmouseover function...
5
2989
by: Mark D Smith | last post by:
Hi anyone know what the java error is on this page? http://www.s-nta.org.uk/index.html Mark
1
2304
by: dasayu | last post by:
Hi, I have a custom object called gridWidget. I am consistantly getting an error in FireFox when I click on an href, which calls a function defined on the object. The generated link looks similar to: javascript:gridWidget.editColumn(3, 3, 'PDDSectionForm', 'pdd_link', ..) The above works fine in IE.
7
9628
by: Coder | last post by:
Hi I have the following code in java script, it is not giving proper output in FIREFOX but running fine in IE... can anybody help me out to make this run in FIREFOX . <script language="JavaScript"> var cntlName; var eleTarget = document.getElementById('hiding'); function showOrHide(){
3
26761
by: jon | last post by:
Hello, I've had long standing code that runs in IE, that I'm testing with firefox unsuccessfully now. The problem seems to be that images that I dynamically create don't fire their onload event in firefox. The onload method I assign is never being called. Any ideas why firefox isn't calling this, or what I can do for a workaround? Below is approxiatemate code of what I'm doing...
9
3822
by: johnd126 | last post by:
I have a cgi program which outputs a fairly hefty amount of html/javascript for doing a complex slide show sorta thing in a variety of areas in the browser. I accomplish this by creating a series of iframes and populating each iframe which its own copy of the code and a list of items to display. It previously had it working tickety-boo with both IE 6 and Firefox. I've had to concentrate on adding new features to the IE side and am now...
7
5398
by: rwaller | last post by:
Works fine in IE, but not in Firefox? Code below, thank you in advance.... http://www.cnusd.k12.ca.us/roosevelt%2Dhs/Leaving_Site/leavingERHSpavelgcy.html <SCRIPT LANGUAGE=vbscript> function callMsgBox2(strMsg) callMsgBox2 = msgBox(strMsg,4,"Leaving ERHS") end function </SCRIPT>
0
9697
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10909
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10295
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
9426
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7830
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
7019
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
1
4492
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
4065
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
3136
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.