I am a VC programmer. Not long ago because of the actual need to learn PHP and JavaScript. Since these two languages are very much like the grammar of C and C + +, I did not take much time to "fix" it.
I usually use JavaScript to customize the page layout, and then use PHP for various database operations. The relationship between the two languages is not like the relationship between MFC and Windows API functions, can be "seamless" porting, so I often encountered difficulties in the practical use, here I put in PHP and Javascrip in the nesting of the issues to be noted briefly.
Routine 1:
Routine 2:
/body>
Comments:
Routine 2 is able to get the correct result, that is, when the user submits the form, it closes the form's window.
The example 1 will get an error indicating "A is not identified" i.e. a is undefined.
The reason is that the scope of window handle A (let me say so) cannot be a "information" (that is, the value of a)
"Pass" to the newly created window. So you can only use Window.close () and the window handle uses the default current value.
http://www.bkjia.com/PHPjc/532228.html www.bkjia.com true http://www.bkjia.com/PHPjc/532228.html techarticle I am a VC programmer. Not long ago because of the actual need to learn PHP and JavaScript. Since these two languages are very much like the grammar of C and C + +, I did not take much time to "fix" it. I'm a ...