Basic knowledge-external references to css, js, and jQurey

Source: Internet
Author: User

Basic knowledge-external references to css, js, and jQurey
The reference text.css file starts with the reference of css. the reference of css includes external references and internal references. However, there are two external references, and the internal references also have two methods. External references include link References and @ important references internal references (in this case, they are not strictly called, but for better classification and better remembering). You can directly use style and direct nesting. We mainly talk about external references and link References: place <link rel = "stylesheet" href = "wcss.css" type = "text/css"/> in the head to call external wcss.css files for html reference. Advantages of using link to reference external css 1. It is helpful for SEO. Using this method to reference external css files will make the source code of html pages much less than adding css styles directly, because the search engine does not crawl css files when crawlers crawl webpages, this makes the html source code very small, making crawlers crawl faster and process less. This increases the weight of the webpage and facilitates ranking. 2. Saving html makes the browser separate threads when downloading the webpage. Just like loading a page and having two lines at the same time opening a page, the webpage can be opened exceptionally fast. (When you browse this page, html source code and css files are downloaded at the same time, making it faster) 3. Easy to modify the style of the webpage. You only need to modify the css style to modify the Artist Style of the webpage, if this method is used in a website project, because the common css basic style is applied on the whole site, it is convenient to modify the whole site style. @ Important <style type = "text/css" media = "screen"> @ import url ("CSS file"); </style> call test. the js file can save the pure JavaScript statement in another "*. js files, which can be called when necessary. Example: Call the test. js file and a prompt is displayed. <Html> <body> <script language = "JavaScript" src = "test. js "> </script> </body>

Related Article

Contact Us

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: 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

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.