Home  >  Article  >  Web Front-end  >  How to hide other attributes in a tag and only display pictures

How to hide other attributes in a tag and only display pictures

php中世界最好的语言
php中世界最好的语言Original
2018-02-09 10:17:163773browse

This time I will show you how to hide other attributes in the a tag Only display pictures, and how to hide other attributes in the a tag and only display picturesNotesWhat are they? The following is a practical case. Let’s take a look.

I often encounter that the 3499910bf9dac5ae3c52d5ede7383485 label has a style that displays a picture, but there is text in the label, and I want the text to be hidden. In many cases, I will think of

text-indent:-9999em;

But today I found that in ie7 and 360 default ie mode, the picture is not displayed, so I checked it online, and the following is To summarize:

The css in ie7 mode is written as follows:

text-indent: -9999em;    
overflow: hidden;  
float: left;     //当然也可以float: right;

The above css can already solve this problem.

360 has IE mode and extreme speed mode. If you want the default extreme speed mode when opening a web page, you only need to add the following sentence to 93f0f5c25f18dab9d176bd4f6de5d30e:

<meta name="renderer" content="webkit">             极速模式  
<meta name="renderer" content="ie-comp">            兼容模式  
<meta name="renderer" content="ie-stand">           IE模式

I believe you have mastered the methods after reading these cases. For more exciting information, please pay attention to other related articles on the php Chinese website!

Related reading:

How to make the textarea text area width and height width and height automatically adapt

##html+css+ How to implement list circular scrolling in javascript

The click event of html hyperlink a jumps to the address pointed to by href

How to display and hide HTML elements through display or visibility

The above is the detailed content of How to hide other attributes in a tag and only display pictures. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn