#1
  1. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Apr 2012
    Posts
    51
    Rep Power
    3

    [Solved] Help with positioning of backgroud images


    Hello everyone

    i need a little help with my positioning of two background images- each of the images is stacked upon the other.

    Both images are held within their own div tag; but the 2nd image's div tag is contained within the div tag of the first ( it is a smaller images).

    The problem that i have is that the CSS Rules ( the Margin Function) for the 2nd Image is now affecting the css rules for the first main image: i am not clear why this is happening as the second image is contained within the div of the first image and should not therefore affect it.

    it might help at this moment if i showed u my rules.


    Code:
    The Div Tags 
    
    
    
    
    <div id="pagewrapper"><!-- START div id pagewrapper -->
    
    <div id="midbody_mainpage"><!-- START  div id midbody   -->
    
    <div class="firstpage_regform"><!-- START  div id midbody   -->
    
    <!-- END  div id firstpage_regform  -->
    
    </div>  <!-- END div id midbody  -->
    
    </div><!-- END div id pagewrapper -->
    
    THE CSS CODE
    
    	#midbody_mainpage{
    		
    		
    		  background: url("/images/pageimages/mainwindowpic.jpg")repeat-x , repeat-y       scroll 0 0 transparent ;
    		  height:399px;
    		  margin-top:0px;
    	
    		}
    		
    		
    		
    		
     .firstpage_regform {
    	background: url("/images/pageimages/reg_form_background2.jpg") ;
    	background-repeat:no-repeat;
    	padding-top: 46px;
    	padding-bottom: 0px;
    	margin-left: 640px;
    	height:292px;
    	width:353px;
    	margin-top:46px;
    	
    }

    THE PROBLEM

    the margin-top from the div of the second smaller image (.firstpage_regform ) is causing the main div to pull down by 46px.

    Can anyone please recommend what i need to do.

    warm regards


    Andreea 115
  2. #2
  3. Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2011
    Location
    The Pleiades
    Posts
    298
    Rep Power
    8
    I'm working on it right now, can I see your styles for 'productwrapper' please?

    Regards,

    NM.
  4. #3
  5. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Apr 2012
    Posts
    51
    Rep Power
    3
    Originally Posted by Nanomech
    I'm working on it right now, can I see your styles for 'productwrapper' please?

    Regards,

    NM.
    hello Nanomech

    thank you so much for your reply. it was very kind of you to look into it

    i have however now resolved the issues.

    warmest regards

    Andreea 115
  6. #4
  7. Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2011
    Location
    The Pleiades
    Posts
    298
    Rep Power
    8
    No problem, I ended up crashing out at about 4am

    Thanks for your reply to let me know as I was just about to start working on it

    Kind regards,

    NM.

IMN logo majestic logo threadwatch logo seochat tools logo