Some time ago, I planned to improve the unfinished online examination system. I looked at the original system and thought that I should log on from the examinee. This part of xueyu has already been implemented through Ajax technology, so what I need to do is to continue to improve.
This part is new to use. Originally, JavaScript was not actually used for asynchronous communication, so it was not so clear at the beginning, with this classification, other people already have the idea of implementation and have achieved more than half of it. So while getting familiar with the code, I tried to guess her ideas.
After the code is almost viewed, the idea is gradually understood and the work will be improved. At this time, I knew the problem was just getting started. The point was that the Javascript seemed to be not executable. I changed it to the left, right, and guessed it again. I finally figured out why I couldn't execute it. It turns out that a place in the vast JavaScript code is not enclosed by quotation marks when passing real parameters. This will lead the compiler to think that it is a variable, but it is actually a constant. In addition, JavaScript does not have any exception prompts. This problem cannot be captured.
This problem is solved, and the system can also run, but there is another problem: After data is transmitted to the backend service through XMLHTTP, the XMLHTTP status readystatus is always 1, this indicates that "the object has been created and the send method has not been called". It is said that this is because the open method is XMLHTTP. open ("get", URL, true), where "true" indicates Asynchronization and can be changed to "false. However, it still does not work after the test. The current value is constantly generated by alert every attempt. This problem has not been solved yet. You can help us think about it.
I used alert and write methods to debug Javascript. I don't know how to use them.