This menu has been removed from Baidu's promotion. The CSS file is removed, and only the core Js actions are retained. Click the title of each item to expand the level-2 subitem menu, if you want to add styles by yourself, you can better match the
Solve the JavaScript page refresh and pop-up window Problems
1. No prompt to refresh the webpage
Have you found that when refreshing some webpages, a prompt window will pop up and click "OK" to refresh the page. Some pages do not prompt. If the
In this chapter, I will provide a very useful page update code in CMS. You can modify any paragraph by clicking the mouse. Click the button to display the modified text. Example
This page is an example. Click a paragraph, edit it, and click Ready.
Recently, I am very interested in js and jq. We can see that jq has many useful plug-ins with different functions, including webUI and jqGrid. I was tempted to create my own jq plug-in. I checked out the official jq plug-in documentation
JQuery obtains and sets Select Options
Obtain Select:
Obtain the selected text in the select statement:
$ ("# DdlRegType"). find ("option: selected"). text ();
Obtain the value selected by the select statement:
$ ("# DdlRegType"). val ();
In ajax, you often need to precisely locate the position of an element. In this case, you not only need to obtain attributes such as the size and position of the element. You also need to know the length and width of the page, browser, and scroll
Transparent effects are one of the simplest effects mentioned by script. aculo. us. Since it is a special effect, it must involve the concept of time and space. We can use setTimeout and setInterval for time. I personally prefer setTimeout. Although
You can use the upper and lower keys on the keyboard to select the implementation code of table rows. The idea is good. For more information, see.
// This is the table to be operated on: This is the first line This is the second line This
Whether the visitor is interested in the website or not, the first impression of the first 20 seconds is crucial, so our design must meet the expectations of the public. Next we will design a personalized navigation menu.
(1): XHTML:
The Code is
The Shadow menu implemented by Div + Js has been used by Microsoft on the homepage of an old version of the website to index all products of the Windows product family. This menu only implements a prototype, to achieve the same effect as Microsoft,
There is a requirement for a recent project that needs to export data to Excel. This is not a problem and there are a lot of online materials. What can I do if the Table contains elements such as Input (text? Practice:
Modify the outerHTML of Input;
Using jQuery is actually just a few lines of code. Even so, due to the js language's way of thinking, I still have not been sure about it. In addition to a css problem, it took a long time to get the effect. Here we mainly use slideToggle () and
The OFFICE control test code mainly controls some office functions. For more information, see.
The Code is as follows:
// The following variables are JS public variables.Var TANGER_OCX_bDocOpen = false;Var TANGER_OCX_filename; // file nameVar
In WinForm program development, some prompts are often displayed using MessageBox, which is simple but practical! On the Web page, the browser also provides script statements such as Alert or Confirm to pop up the prompt window, such:
However,
The definition and usage of split is mainly to split strings into arrays, and then perform operations such as output. It is a commonly used function. Split definition and usage
The split () method is used to split a string into a string
When processing text box input values in javascript, The & quot; remove blank & quot; function is often used. Anyone who has used jQuery knows that jQuery provides a function such as trim (), which can easily help us achieve this effect. However, if
For people who are engaged in or planning to engage in programming, object-oriented is a familiar word. Almost everyone can list some object-oriented programming languages, such as C ++, JAVA, c. In fact, object-oriented thinking is independent of
Select: add the selected select option to another select, or click Add all to add all options. I wrote a very simple jquery plug-in, which can be implemented by calling the functions on the page.
Plug-in source code (listtolist. js ):
The Code is
Why can't the floating ad couplet Code use the couplet code in the web page of the XHTML language? Check its expression in the xhtml, and the result is very simple. This is because, according to the standard, the scroll bar of the form we see should
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