• Post Reply Bookmark Topic Watch Topic
  • New Topic

CSS  RSS feed

 
Ranch Hand
Posts: 51
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

I need to write the title "Edit Attributes" using <h1>...<h6> tags but I want to keep the background-image used in css.Here is the code that I use:

<td height="20" colspan="4" class="BgTitle">Edit Attributes</td>

.BgTitle{
font-size: 9pt;
font-family: Arial;
color: #434343;
font-weight: bold;
text-transform: uppercase;
padding: 2px 15px 2px 15px;
background-image: url(../images/back.gif);

}

Is there a way to use background-images with h1 tags???

Thanks.
 
author
Rancher
Posts: 15385
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Have you tried to use...


Eric
 
Giomar Guevara
Ranch Hand
Posts: 51
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
didn't work
 
Eric Pascarello
author
Rancher
Posts: 15385
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Works for me. Do you have the relative URL pointing to the correct directory?

Eric
 
Giomar Guevara
Ranch Hand
Posts: 51
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
the relative path is fine...I tried to put a color to test if the css works but is like it doesn't recognize anything.

This is part of my jsp:
<tr>
<td colspan="3" height="20"><h5> Edit Variations</h5></td>
</tr>

and this is my css

h5{
background-image: url(../images/back.gif);
background-color: #00ff00;
}

what can be wrong???
 
Eric Pascarello
author
Rancher
Posts: 15385
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Why are you using a heading inside of a table cell? seems silly to me when the code can be applied to the cell or table row itself with class names and has a cleaner markup feeling.

BUT this works for me....


works for me on IE 7 and FF 1.5....

Eric
 
Giomar Guevara
Ranch Hand
Posts: 51
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I know...but I'm modifying the page for accessibility and the client wants us to use <h1>...<h5> tags...
 
Those cherries would go best on cherry cheesecake. Don't put those cherries on this tiny ad:
Why should you try IntelliJ IDEA ?
https://coderanch.com/wiki/696337/IntelliJ-IDEA
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!