In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-03-31 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >
Share
Shulou(Shulou.com)06/01 Report--
Xiaobian to share with you what are often confusing attributes in HTML, I believe most people still do not know how, so share this article for your reference, I hope you have a lot of harvest after reading this article, let's go to understand it together!
Difference between link and @import
Since both link and @import can be used to introduce css, what's the difference? How do we choose?
Link is a type of XHTML tag that can be used to load css and other rel attributes, while @import can only be used to load css.
The link tag loads with the page when the css is loaded, while @import waits until the page is fully loaded.
link is an XHTML tag that has no compatibility issues, while @import is introduced in CSS 2.1 and is not supported by older browsers.
The link tag can control its attributes through Javascript code, while @import cannot.
@import supports the reintroduction of other css files into css files to facilitate the management of multiple css files.
Because the files introduced by @import need to be loaded after the page is fully loaded, if the network speed is slow, the page will flash, so it is recommended to use the link tag instead of @import.
readonly and disabled attributes
The readonly and disabled attributes of html elements are generally used to disable the content of the form, but there are differences between the two.
The readonly attribute applies only to input(text,password) and textarea elements, while disabled applies to all form elements, including select,radio,checkbox,button, etc.
When disabled is used on a form element, the value of the element is not passed to the server with the action request of the form, but the value of the element using readonly can be passed to the server.
Here are some suggestions for using both.
The unique identifier pre-filled in the form for the user is not allowed to be changed by the user, and the readonly attribute needs to be passed to the background.
After the user submits the form element and waits for server-side validation, this process should set the element to disabled, and button and submit should also be set to disabled to prevent duplicate submissions.
The above is "What are the attributes that are often confused in HTML?" All the contents of this article, thank you for reading! I believe that everyone has a certain understanding, hope to share the content to help everyone, if you still want to learn more knowledge, welcome to pay attention to the industry information channel!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.