用JavaScript控制CSS其實很簡單

來源:互聯網
上載者:User
用JavaScript控制CSS其實很簡單,基本上每個DOM對象都有一個style對象,只要把css屬性裡的"-"去掉,並讓隨後的字母變為大寫就可以作為屬性使用了,例如:element.style.backgroundColor="#f00";在css是:選擇符 {background-color:#f00}
/**接jsp數組
String[] primarykey =request.getParameterValues("primaryKey");
String[] monthjlsl = request.getParameterValues("monthjlsl");
String[] monthjlje = request.getParameterValues("monthjlje");
String[] qdbh = request.getParameterValues("primaryKey1");
for(int j=0;j<PRIMARYKEY.LENGTH;J++){
    for (int i=0 ; i<QDBH.LENGTH;I++){
        if(primarykey[j].equals(qdbh)){
            DaoPut.SaveMonthdata(signId,parent,qdbh,monthjlsl,monthjlje,nowdate);
        }
    }
}
相關文章

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.