Solved

asp.net css image could not be display

Posted on 2011-02-15
3
906 Views
Last Modified: 2012-05-11
trying to display image from css file ,

 cssfilepath
aspx
----
<head id="Head1" runat="server">
<link rel="stylesheet" href="Images/Css/gray.css" type="text/css" />

gray.css
--------
.mainpic
{
	background:url('../Images/Home/mainpic.gif');
	background-repeat:no-repeat;
}

Open in new window

0
Comment
Question by:doramail05
  • 2
3 Comments
 
LVL 10

Expert Comment

by:hosneylk
ID: 34903448
try this instead
background-image: url(../Images/Home/mainpic.gif);

Open in new window

0
 
LVL 1

Accepted Solution

by:
doramail05 earned 0 total points
ID: 34903466
resolved :

../../Images/Home/mainpic.gif
0
 
LVL 1

Author Closing Comment

by:doramail05
ID: 34936613
changed the relative path
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

This article describes how to create custom column layout styles for Bootstrap. The article uses 5 columns to illustrate the concept, but the principle can be extended to any number of columns.
Today, the web development industry is booming, and many people consider it to be their vocation. The question you may be asking yourself is – how do I become a web developer?
In this tutorial viewers will learn how add a full-size background image to a webpage using CSS3. Create a new HTML document with an internal stylesheet.: In CSS, define the html element to have a background image. Use a high resolution image.: In t…
In this tutorial viewers will learn how to customize the background color and font color of highlighted text using the ::selection element in CSS Begin by defining the selected text as an element in CSS by typing "::selection": Style the ::selection…

713 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question