Solved

Empty div not showing

Posted on 2013-01-23
2
364 Views
Last Modified: 2013-01-23
I have a div that is empty of content but does have a background image.  I would like the entire div to open so you can see the entire background image.

At the moment, it is not opening at all.

.index-amp	{
	width:50%;
	height:50%;
	left:0%;
	top:0%;
	float:left;
	clear:left;
	position:relative;
	background-image:url(../../img/items/index-amp-320.png);
	background-repeat:no-repeat;
	display:block;
	background-size:100%;
	z-index:0;
}

Open in new window

0
Comment
Question by:rgranlund
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 18

Assisted Solution

by:dj_alik
dj_alik earned 250 total points
ID: 38811596
if you set height in pixels  units it will  work.
also  check your background-image:url path.
0
 
LVL 30

Accepted Solution

by:
LZ1 earned 250 total points
ID: 38811654
You do have to set a height if you want it to display. But if it's supposed to be empty then why not just place the image inside the div and avoid the background?
0

Featured Post

Independent Software Vendors: 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

This article explains how to prepare an HTML email signature template file containing dynamic placeholders for users' Azure AD data. Furthermore, it explains how to use this file to remotely set up a department-wide email signature policy in Office …
Many old projects have bad code, but the budget doesn't exist to rewrite the codebase. You can update this code to be safer by introducing contemporary input validation, sanitation, and safer database queries.
In this tutorial viewers will learn how to embed custom externally-hosted Google Fonts using the Google Font API in CSS Go to the Google Fonts website at google.com/fonts: Browse or search based on font properties or name to find a suitable font for…
The viewer will learn how to create and use a small PHP class to apply a watermark to an image. This video shows the viewer the setup for the PHP watermark as well as important coding language. Continue to Part 2 to learn the core code used in creat…

738 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