I am using FF 3.6 with FB 1.5.2 for developing a site using Javascript as well as PHP/MySQL. I have installed Apache 2.2 (on my Windows 6.x [Vista Home Premium 32-bit]).
In one PHP document, I load two JS files, one called "dbSchema.js" and the other "mysqlClass.js". The first JS file just defines a single variable (serverSchema) which is an array of arrays of strings the contain names and characteristics of a MySQL database, with all its structural components, in this case one database containing two tables, and each table containing a variable number of fields whose characteristics are defined (field name, field type and length, field collation, null and default setting status, etc). I am using FB to step through the bugs in the JS code naturally. The problem is that both db.Schema.js and mysqlClass.js have been loaded the coded in the Script panel window not as they are. Lines of code are repeated and inserted randomly. This makes stepwise tracing/ debugging impossible. There are two curious things here (#2 is really curious): For the purposes of being concise about the problem, I have stripped the irrelevant content and code of the PHP document into an HTML file "dbSchema.html" (the URL to this is at the bottom of this message). 1. FB seems to have the code for execution correctly within its memory, but the problem is the code it presents to the user in the Script panel window. For example. line 347 of mysqlClass.js is the entry point or function definition (line #1) of the DatabaseSchema object, which is called from the HTML document. But line 347 is shown in the Script panel as the 7th line of the function definition above it, the definition for the Database object. I could use FB to trace execution if I follow the line numbers in FB alone, but I have to have my text editor (that I use for editing all documents) open side-by- side to follow the trace. 2. Now here's the real astonishment: if you click the URL below to see the improper loading of the Script panel, you may not actually see it. You may actually be able to do the step trace properly in FB. Why? Because in order to present this problem to you and this group, I uploaded the three files (dbSchema.html, dbSchema.js, mysqlClass.js) to a free web hosting site we use, and then downloaded the HTML file and FB loaded and presented the code of the JS files properly, without randomly repetitive and inserted lines of code!! In other words, the problem seemed server dependent!! I have re-started Windows (and thus the server), and the problem of badly presented code still occurs at http://localhost. And FB loads and presents the code correctly when it is loaded from host http://nilgulkaradeniz.awardspace.info. Is this bizarre? This problem, and all the code of the JS files, is brought together and explained in fuller detail at http://nilgulkaradeniz.awardspace.info/dbSchema.html. -- You received this message because you are subscribed to the Google Groups "Firebug" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/firebug?hl=en.
