Page 1 of 1

my program just gone crazy

Posted: Sun Jun 24, 2012 7:19 am
by wvoyance
:cry: :cry:

Yesterday, I suddenly found my program got crazy, after busy reinstall the system for a week or so....

I modified the program, categories.php of OSC, which is supposed to generate a form for new products.
My modification made the filling easier so that it can automatically fetch products information from a library
as soon as I provided the ISBN. The automatically fetch data is of course triggered by a javascript event onchange,
and the javascript called AJAX to get the data.

It was all right. But now, before I even entered an ISBN, the form is filled, with some fixed data. I mean, I just start the program and tell it I am going to fill the form. It is suppose to give me an empty form. The event has not even be triggered.

The pre-filled data is indeed one of my previously inserted product. I even tried to remove that product,
the the filled form is still the same.

I remember I made some modifications to the program, and I have removed those modifications, but no use. :roll:

I just don't know where to start debug. :dubious:

Re: my program just gone crazy

Posted: Sun Jun 24, 2012 3:32 pm
by requinix
Is the browser filling in those fields?

Re: my program just gone crazy

Posted: Sun Jun 24, 2012 4:19 pm
by wvoyance
requinix wrote:Is the browser filling in those fields?
I don't know who filled it. But the HTML code already replaced.
I mean, it should be replaced by jQuery after I entered ISBN and obtained data from a library, but now at the time
the form is loaded it is filled. :roll:

Re: my program just gone crazy

Posted: Sun Jun 24, 2012 4:47 pm
by Jonah Bron
Are you talking about some HTML content, or just the value of the text field? Perhaps you could use view source to see if your code is populating the field's value, or the browser. Without any code, we can't give much guidance, an excerpt where the problem seems to be originating would be helpful.

Re: my program just gone crazy

Posted: Sun Jun 24, 2012 8:24 pm
by wvoyance
Jonah Bron wrote:Are you talking about some HTML content, or just the value of the text field? Perhaps you could use view source to see if your code is populating the field's value, or the browser. Without any code, we can't give much guidance, an excerpt where the problem seems to be originating would be helpful.

I am talking about just the value of the text field, which my code should use jQuery to replace later after
I input the ISBN. The field is indeed replaced.....But how could it happen?
I have not input the ISBN to ask jQuery to replace the content.


What is the "view source" you are talking about? Another software?

(some of you complained for my posting at other site, but the code is too long to post here.)

One of the strange things is the replaced content is some fixed information.
Actually one of the product I had in my database.
I tried to delete that item. But the content never changed.

Re: my program just gone crazy

Posted: Sun Jun 24, 2012 10:11 pm
by Jonah Bron
wvoyance wrote:What is the "view source" you are talking about? Another software?
Ah, I should have been more clear. Right-click on the page in your browser and select "View source". Browse through the code that comes up and look for the text field, and see if it has a value set in the source code. If you like, you can paste the text field from the source code here.
wvoyance wrote:(some of you complained for my posting at other site, but the code is too long to post here.)
You made a good call in this case, that is quite a lot of code.