Javascript closes the current window
Window. Close (), but it will prompt "the webpage you are viewing is trying to close the window. Close the window ?", How can I not bring up this prompt?
"If you open this webpage for the first time, window.
The default script debugging is disabled. To enable it, you must:
Tools-> Internet Options... -> Advanced-> disable script debugging
On XP SP2, the options are split into two items:
Tools-> Internet Options... -> Advanced-> disable script
When using JavaScript to operate XML objects, we often use XPath to find the XML nodes to be operated on. However, sometimes "unknown method" appears after the selectnodes/selectsinglenode method is called ." If you are sure that the method name is
The solution to the Javascript syntax error dialog box is displayed !!!!!
1. CheckCodeCheck whether there is a syntax error. js call error. Missing flag error. Another error is the error of the stenographer Code. These should be very careful. In
Object-Oriented ProgrammingJavascript uses "Object-Oriented Programming" or "Object-Oriented Programming. The so-called "Object-Oriented Programming" refers to dividing the scope of JavaScript into large and small objects. objects are still divided
1. function object
JavaScript does not overload the concept that each object implies an arguments object (actually received parameter). The Length attribute receives the expected parameters of the object, arguments. length, indicating the number of
Compatibility between IE and Firefox in Javascript
1.doc ument. formname. Item ("itemname ")Note:In IE, you can use document. formname. Item ("itemname") or document. formname. elements ["elementname"];In Firefox, only document. formname.
In millions of pages, JavaScript is used to improve design, validate forms, detect browsers, create cookies, and so on.
Javascript is the most popular scripting language on the Internet and can run in all major browsers, such as Internet Explorer,
You can create three message boxes in javascript: Warning box, confirmation box, and prompt box.Instance
Warning box
Warning box with lines
Confirmation box
Prompt box
Warning box
The warning box
Document directory
Syntax for creating a function:
Example
A function is an event-driven or reusable code block that is executed when it is called.Instance
Function
How to call a function.
Functions with Parameters
Document directory
1:
2:
An array object uses a separate variable name to store a series of values.Instance
Create an array
Create an array, assign values to it, and then output these values.
For... in statement
Use
We can use JavaScript to create dynamic images.Instance
Button Animation
Two different events are used to drive two corresponding functions, and two corresponding images are switched to create an animation effect.
Javascript Animation
The parameters of the function being executed and the function that calls it.
[Function.] arguments [N]Parameter Function: option. Name of the function object currently being executed. N: option. The index of the parameter value starting from 0 to
The following solutions are available with the help of Google:
In Ajax, the interface is often changed through innerhtml, Which is simpler than Dom.For example:Element. innerhtml ="Something"However, in IE, "unknown runtime error" may sometimes
Hasownproperty: if the object has a property with the specified name, this method returns true; otherwise, false.
This method cannot check whether the property exists in the prototype chain of the object. The property must be a member of the object.
The formula interpreter is relatively simple. I thought it would take three days and the result was still used for a week. It seems that I have to re-evaluate my productivity.
Question:
Principle:
1. parse the formula into a sequence of
When I went to the Forum today, I saw a friend asking if I had a school dedicated to teaching Javascript. Here I would like to share my suggestions with you about front-end Javascript development experience over the past three years, it also
1. Understand Navigator objects
Navigator: get information about the browser. all browsers support Navigator objects and are read-only.
Ii. attributes of the Navigator object
-- The following reference:
Read chapter 4th and chapter 7 of JavaScript advanced programming.
1. Basic Concepts 1. What is the execution environment? (Execution context)
The execution environment defines other data that variables or functions have the right to access and
after you click the link, the page will be rolled up to the TOP, # The default anchor is # TOP
after you click the link, the page does not move and only opens the link.
different browsers have different functions.
After clicking the link, if you
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service