头闻号

天津市浩铭化工有限公司

二元醇|通用有机试剂|医药中间体|其他类型日用化学品|食品添加剂|PVC

首页 > 新闻中心 > 科技常识:CSS和“★”字符制做的中国国旗实现代码
科技常识:CSS和“★”字符制做的中国国旗实现代码
发布时间:2024-09-22 07:35:11        浏览次数:0        返回列表

今天小编跟大家讲解下有关CSS和“★”字符制做的中国国旗实现代码 ,相信小伙伴们对这个话题应该有所关注吧,小编也收集到了有关CSS和“★”字符制做的中国国旗实现代码 的相关资料,希望小伙伴们看了有所帮助。

在网上看见 某位牛人用CSS做的红旗 就是很牛! 上图先看: <html> <head> <title>CSS中国国旗</title> <style type="text/css"> .all{ background-color:red; width:960; height=640; } .five{ background-color:red; width:480; height=320; } .big{ position:absolute; background-color:red; margin-top:64px; margin-left:64px; color:yellow; font-size:192px; } .small{ position:absolute; background-color:red; color:yellow; font-size:64px; } .s1{ margin-top:32px; margin-left:288px; filter:progid:DXImageTransform.Microsoft.Matrix(SizingMethod='auto expand',M11=0.6565,M12=0.7543,M21=-0.7543,M22=0.6565); } .s2{ margin-top:96px; margin-left:352px; filter:progid:DXImageTransform.Microsoft.Matrix(SizingMethod='auto expand',M11=0.8978,M12=0.4404,M21=-0.4404,M22=0.8978); } .s3{ margin-top:192px; margin-left:352px; filter:progid:DXImageTransform.Microsoft.Matrix(SizingMethod='auto expand',M11=0.9994,M12=0.0359,M21=-0.0359,M22=0.9994); } .s4{ margin-top:256px; margin-left:288px; filter:progid:DXImageTransform.Microsoft.Matrix(SizingMethod='auto expand',M11=0.9357,M12=-0.3528,M21=0.3528,M22=0.9357); } </style> </head> <body> <div class="all"> <div class="five"> <div class="big">★</div> <div class="small s1">★</div> <div class="small s2">★</div> <div class="small s3">★</div> <div class="small s4">★</div> </div> </div> </body> </html> 第2种代码,全部镶嵌在“<body>..</body>”网页标签里: <div style="background-color:red;width:960;height=640;"> <div style="background-color:red;width:480;height=320;"> <div style="z-index:2;position:absolute;background-color:red;margin-top:64px;margin-left:64px;color:yellow;font-size:192px;">★</div> <div style="z-index:2;position:absolute;background-color:red;margin-top:32px;margin-left:288px;color:yellow;font-size:64px;filter:progid:DXImageTransform.Microsoft.Matrix(SizingMethod='auto expand',M11=0.6565,M12=0.7543,M21=-0.7543,M22=0.6565);">★</div> <div style="z-index:2;position:absolute;background-color:red;margin-top:96px;margin-left:352px;color:yellow;font-size:64px;filter:progid:DXImageTransform.Microsoft.Matrix(SizingMethod='auto expand',M11=0.8978,M12=0.4404,M21=-0.4404,M22=0.8978);">★</div> <div style="z-index:2;position:absolute;background-color:red;margin-top:192px;margin-left:352px;color:yellow;font-size:64px;filter:progid:DXImageTransform.Microsoft.Matrix(SizingMethod='auto expand',M11=0.9994,M12=0.0359,M21=-0.0359,M22=0.9994);">★</div> <div style="z-index:2;position:absolute;background-color:red;margin-top:256px;margin-left:288px;color:yellow;font-size:64px;filter:progid:DXImageTransform.Microsoft.Matrix(SizingMethod='auto expand',M11=0.9357,M12=-0.3528,M21=0.3528,M22=0.9357);">★</div> </div> </div> 提示:您可以先修改部分代码再运行

来源:爱蒂网