根据html代码的不同来分成两大类方法,如下
html代码:
hello see
第一种方法:text-indent
.replace-indent{
立即学习“前端免费学习笔记(深入)”;
height:200px;
width:200px;
background:url();
text-indent:-9999px;
}
第二种方法:
.replace-indent{
立即学习“前端免费学习笔记(深入)”;
height:200px;
width:200px;
background:url();
text-indent:100%;
white-space:nowrap;
overflow:hidden;
}
第三种方法:
.replace-indent{
立即学习“前端免费学习笔记(深入)”;
height:0px;
width:200px;
background:url();
padding:200px 0 0 0;
overflow:hidden;
}
第四种方法:before
.replace-indent{
立即学习“前端免费学习笔记(深入)”;
width:image's width;
height:image's height;
overflow:hidden;
}
.replace-indent : before{
content:url();
}
html代码:
hello see
第一种方法:
.replace-indent{
立即学习“前端免费学习笔记(深入)”;
height:200px;
width:200px;
background:url();
}
span{
display:none;
}
第二种方法:
.replace-indent{
立即学习“前端免费学习笔记(深入)”;
height:200px;
width:200px;
background:url();
}
span{
width:0;
height:0;
display:block;
overflow:hidden;
}
第三种方法:
.replace-indent{
立即学习“前端免费学习笔记(深入)”;
height:200px;
width:200px;
background:url();
}
span{
clip-path:polygon(0px 0px,0px 0px,0px 0px,0px 0px,0px 0px);
-webkit-clip-path:polygon(0px 0px,0px 0px,0px 0px,0px 0px,0px 0px);
}
每个人都需要一台速度更快、更稳定的 PC。随着时间的推移,垃圾文件、旧注册表数据和不必要的后台进程会占用资源并降低性能。幸运的是,许多工具可以让 Windows 保持平稳运行。
Copyright 2014-2025 https://www.php.cn/ All Rights Reserved | php.cn | 湘ICP备2023035733号