gq0324

JS更改字体颜色、背景颜色

CSS 颜色十六进制值  http://www.w3school.com.cn/cssref/css_colorsfull.asp 

CSS background-color 属性   

body
  {
  background-color:yellow;
  }
h1
  {
  background-color:#00ff00;
  }
p
  {
  background-color:rgb(255,0,255);
  }


$("body").css("background-color","#000");
$("#yz").css("background-color","#F5FFFA");
$("#Fdrendegeren").css("background-color","#000");

$("#rendegeren").find("thead").find("tr").each(
function(){
$(this).css("background-color","#000");
$(this).find("th").each(
function(){
$(this).css("color","green");
$(this).css("fontSize", "30px");
$(this).css("lineHeight", "60px");
}
)
}

分类:

技术点:

相关文章:

  • 2021-11-09
  • 2021-05-05
  • 2021-08-23
  • 2021-06-06
  • 2021-09-18
  • 2021-07-24
  • 2021-11-21
  • 2021-10-11
猜你喜欢
  • 2021-12-10
  • 2022-02-10
  • 2021-07-17
  • 2022-01-19
  • 2022-01-06
  • 2021-09-23
  • 2021-08-05
相关资源
相似解决方案