Solved

asp.net css image could not be display

Posted on 2011-02-15
3
902 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

What Security Threats Are You Missing?

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

Introduction If you're like most people, you have occasionally made a typographical error when you're entering information into an online form.  And to your consternation, the browser remembers the error, and offers to autocomplete your future entr…
Building a website can seem like a daunting task to the uninitiated but it really only requires knowledge of two basic languages: HTML and CSS.
In this tutorial viewers will learn how to position items using CSS's three positioning types Create a new HTML document with an internal stylesheet.: Create another div in CSS and name it Absolute : Type "position:absolute;" and "top:10px; left:50p…
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…

758 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

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now