When attempting to apply an image in the background of an HTML tag using CSS, I am encountering an issue where the image is not visible during runtime, even though it appears during design time. Additionally, I am curious as to why the full path needs to be provided for the image to display correctly.
.small-heading
{
background:url(C:\Users\Admin\Documents\Visual Studio 2010\Projects\WebApplication1 \WebApplication1\Images1\small-heading.gif);
width: 105px;
height: 20px;
float: left;
font-size: 0.9em;
line-height: 18px;
font-weight: normal;
color: #7a7a7a;
overflow: hidden;
padding: 0 0 0 3px;
}
<strong class="small-heading">
<a href="#" id="lnkPassword" >Change Password</a></strong>
</td>
The image in question is located within a folder named Image1 directly in the root. I attempted using the following code:
background:url(Images1\small-heading.gif);
Unfortunately, this approach did not yield the desired result...