jsf 2 - css not working in jsf -


this question has answer here:

i created css file prime-faces , have tired make not working .

this style.css file

 <!doctype html public "-//w3c//dtd xhtml 1.0 transitional//en" "http://www.w3.org        /tr/xhtml1/dtd/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" dir="rtl">  <head> <meta content="text/html; charset=utf-8" http-equiv="content-type" /> <title>untitled 1</title> <style type="text/css"> *{  padding:0px;  margin:0px;  }  body{ background-color:#ffffff;   }  .head1{ background-repeat:repeat-x; background-image: url('images/rd-el_03.png'); height:174px;  }  .head2{ background-image: url('images/rd-el_02.png'); width:364px; height:174px; margin-left:auto; margin-right:auto; background-repeat:no-repeat;   }  img{  border:0;   }  .footer1{    background-image: url('images/rd-el_07.png');   height:87px;   background-repeat:repeat-x;      }   .footer2{   background-image: url('images/rd-el_06.png');   float:left;   width:89px;   height:87px;   background-repeat:no-repeat;     }  .footer3{    background-image: url('images/rd-el_09.png');   width:272px;  height:87px;  float:right;  background-repeat:no-repeat;    }  </style>  </head>   <body>   <div class="head1">  <div class="head2"></div> </div>   <div class="footer1">  <a href="http://tl4s.com.sa" title="تصميم منتدى"><div class="footer2"></div></a>  <div class="footer3"></div>  </div>      </body>   </html> 

this style.css under webcontent |-- resources | -- css |-- style.css :

i have putted code in xhtml file no luck

 <h:head>   <h:outputstylesheet name="css/styles.css" />  </h:head> 

well, doesn't css file. html/xhtml file has css code embedded in it. remove html code , inside of tags, put in css file! work. css file looks like:

----------------------------------start----------------

.body{  css code here }  .property1{  css code here } 

-------------------------------------------end------------------

there should absolutely nothing else in it.


Comments

Popular posts from this blog

c# - Send Image in Json : 400 Bad request -

jquery - Fancybox - apply a function to several elements -

An easy way to program an Android keyboard layout app -