473,396 Members | 1,995 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Gap between DIV and Container

KeredDrahcir
426 256MB
I'm creating a box that had a container divsion and then an innner division for the content. However there is a gap of about ten pixel between the bottom of the container and a bottom of the inner divsion. I need them to be the same height since the inner divison has a image border that had to go all the way to the bottom.

CSS:
Expand|Select|Wrap|Line Numbers
  1. .my_div{
  2.     border: 0px solid #ffffff;
  3.     width: 272px;    
  4.     vertical-align: top;
  5.     padding-top: 0;
  6.     margin-top: 0;
  7.     padding-bottom:0;
  8.     margin-bottom: 0;
  9. }
  10.  
  11. .my_div div{
  12.     background: url(../images/column_bg.jpg) repeat-y;
  13.     padding: 0 0 0 0;
  14.     margin: 0 0 0 0;
  15. }
HTML:
Expand|Select|Wrap|Line Numbers
  1. <div class="my_div">
  2.   <div>
  3.     <h3>Title</h3>
  4.       <div><p>Contwnt</p></div>
  5.   </div>
  6. </div>
Can anyone suggest how to get both division the same height.
Jun 27 '11 #1
3 2508
ilya Kraft
134 100+
Alright try this,

Expand|Select|Wrap|Line Numbers
  1. .my_div{
  2.     width:272px;    
  3.     vertical-align:top;
  4.     padding-top:0;
  5.     margin:0;
  6. }
  7.  
  8. .my_div div{
  9.     background: url(../images/column_bg.jpg) repeat-y;
  10.     padding:0;
  11.     margin:0;
  12. }
  13.  
And I think it could be that background image that is causing the problem, make sure that heights are adjusted so background image matches div's.
Jun 27 '11 #2
KeredDrahcir
426 256MB
That hasn't made any difference. The background image needs to scroll to match the height of the division which can changes its height depending on what is put inside it.
Jun 28 '11 #3
KeredDrahcir
426 256MB
I've solved it. I added on pixel of bottom padding onto the
.my_div div anf it's foxed it. Does anyone know why?
Jun 28 '11 #4

Sign in to post your reply or Sign up for a free account.

Similar topics

2
by: Maitre Bart | last post by:
What I want to perform is calling a member function of container 1 (CRunner), using as argument the value of a container 2 (CNames). The purpose is to transfer values from C2 into C1 using a...
3
by: jignesh shah | last post by:
Hi all, Is there a way to recover a single container if its been corrupted or mark bad without restoring whole tablespace? environment: db28.1/aix5.1/tsm/rs-6000. Regards Jignesh
9
by: horizon5 | last post by:
Hi, my collegues and I recently held a coding style review. All of the code we produced is used in house on a commerical project. One of the minor issues I raised was the common idiom of...
7
by: toton | last post by:
Hi, I want a circular buffer or queue like container (queue with array implementation). Moreover I want random access over the elements. And addition at tail and remove from head need to be low...
11
by: food4uk | last post by:
Dear all : I am not good at programming, please give a hand. My data structure is very similar as an array. I actually can use the std::vector as container to organize my data objects. However,...
2
by: Daniel Lipovetsky | last post by:
I would like for an object to "report" to a container object when a new instance is created or deleted. I could have a container object that is called when a new instance is created, as below. ...
1
by: Miked | last post by:
Hello: I'm relatively new to CSS, and I'm doing a site where I don't want to use any tables. I've gotten pretty far, and the site has the layout I want. My only problem is that I'm using the...
18
by: Goran | last post by:
Hi @ all! Again one small question due to my shakiness of what to use... What is better / smarter? private: vector<MyClass_t* itsVector; OR...
36
by: Peter Olcott | last post by:
So far the only way that I found to do this was by making a single global instance of the container class and providing access to the contained class, through this single global instance. Are...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.