Text-overflow:ellipsis non-IE browsers for alternative applications

Source: Internet
Author: User
Browser

Text-overflow:ellipsis everyone used it, in win everyone knows IE and opera can be done, if you look at the following code you will not be excited?

Text-overflow:ellipsis;
-o-text-overflow:ellipsis;
-icab-text-overflow:ellipsis;
-khtml-text-overflow:ellipsis;
-moz-text-overflow:ellipsis;
-webkit-text-overflow:ellipsis;

Do not be excited, the support of all support, the other is to cheat children drop. The private properties of the basic non IE browser will start with-xxx-,-o-is the Presto engine of opera private,-icab-is icab private,-khtml-is khtml as the engine of the browser (such as Konqueror Safari),- Moz-is a browser with Mozilla's Gecko engine (such as Firefox,mozilla),-webkit-is a browser (such as Safari, Swift) with WebKit rendering engine (khtml derivative).

It's not like-moz-text-overflow is now useful, it's a fanciful way of writing, when a browser developer decides that a browser supports a property that has not yet been recognized, it will typically precede the attribute with-xxx-, indicating that this is a private property of the browser, and, of course, Most of these attributes come from CSS3, which may be useful when the browser is upgraded

This code is seen on the Css3.info, before is not such a drop, do not know when the change.

Firefox to achieve Text-overflow also have almost the line drop, one is JS+XBL, another CSS: After, before trying to write with XBL to monitor the width of the text of the coordination: After, do not want to know I was a failure, if the single XBL can line, Others do not need to cooperate with JS to write.



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

  • 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.