• Post Reply Bookmark Topic Watch Topic
  • New Topic

CSS

 
mallik karjuna
Greenhorn
Posts: 1
IBM DB2 Firefox Browser
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi
I imported css into java like below

buffer.append("<link rel=\"stylesheet\" href=\"theme/oppt.css\" type=\"text/css\" title=\"cst1\" id=\"sheet1\" />");


and appy css to the below label IBMConfidential222 like below

buffer.append("<tr class=\"redc1234\"><td lotus_celltype=\"label\" colspan=\"25\" bgcolor=\"#ffffff\" align=\"left\" valign=\"bottom\" height=\"10\">IBM Confidential222</td></tr>\n");


in oppt.css I have mentioned like .redc {
font-size: 18;
color: #FF0000
}


but when running the application IBM Confidential222 is printed normally without showing font,red color



 
Bear Bibeault
Author and ninkuma
Marshal
Posts: 65530
105
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Is this in a JSP? Why do you have Java code creating the <link> tag?

In any case, your href should be server-relative, beginning with the application's context path. Page-relative URLs such as you are using are fagile even when you can get them to work. See the JSP FAQ for more info.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!