Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

CSS Forum


You are currently viewing our CSS Forum as a guest. Please register to participate.
Login



Reply
Overlap image outside of div height
Old 05-03-2009, 06:26 PM Overlap image outside of div height
MattCoops's Avatar
Ultra Talker

Posts: 423
Name: Matt Cupan
Location: Charlotte, NC
Trades: 0
I would like to place an image that extends outside of the top and bottom boundaries of a <div>.
I attached an image describing what I mean.
How would I accomplish this? Should I stick the image in another <div>?
Attached Images
File Type: jpg img_overlap.jpg (9.3 KB, 2 views)
__________________
Matt - Tweeting
Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE

read my
Please login or register to view this content. Registration is FREE
MattCoops is offline
Reply With Quote
View Public Profile Visit MattCoops's homepage!
 
 
Register now for full access!
Old 05-03-2009, 07:48 PM Re: Overlap image outside of div height
LadynRed's Avatar
Defies a Status

Posts: 10,016
Location: Tennessee
Trades: 0
Probably the best way to do that is with absolute positioning and setting the image to have a high z-index.
__________________
Web Goddess & Web Standards Evangelist :) - Tables Be Gone !!

Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE

LadynRed is offline
Reply With Quote
View Public Profile
 
Old 05-03-2009, 07:59 PM Re: Overlap image outside of div height
MattCoops's Avatar
Ultra Talker

Posts: 423
Name: Matt Cupan
Location: Charlotte, NC
Trades: 0
Can I be so humble to ask for an example?
__________________
Matt - Tweeting
Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE

read my
Please login or register to view this content. Registration is FREE
MattCoops is offline
Reply With Quote
View Public Profile Visit MattCoops's homepage!
 
Old 05-04-2009, 09:52 AM Re: Overlap image outside of div height
Novice Talker

Posts: 13
Name: Anita
Trades: 0
Hi Matt,
I have done website with similar effect and I use following code for this.

css
Code:
#header{ 
   position:relative; 
   height:350px; }
#logo{     
    position:absolute; 
    top:0; 
    left:25px; 
    z-index:99; 
    padding-top: 10px;
    width:180px;
    height:150px; 
    background-color:#FFFFFF;
    border:1px solid #ddd;
    border-top:none;    
    text-align:center;}
html

Code:
<div id="header">

<div id="logo"><a href="index.html"><img src="img/logo.jpg" alt="Logo" /></a></div>

</div>
Logo is the element over the header.

Hope it will help you.

Good luck,
anita@sadurska.com
anikasara is offline
Reply With Quote
View Public Profile Visit anikasara's homepage!
 
Old 05-04-2009, 10:20 AM Re: Overlap image outside of div height
MattCoops's Avatar
Ultra Talker

Posts: 423
Name: Matt Cupan
Location: Charlotte, NC
Trades: 0
thank you

only problem with that is the image is a transparent gif
the div is centered horizontally between two adjacent divs (above and below) that have different colored backgrounds (same gray color). Won't the #logo div id take the background color of the parent div it's within?
__________________
Matt - Tweeting
Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE

read my
Please login or register to view this content. Registration is FREE
MattCoops is offline
Reply With Quote
View Public Profile Visit MattCoops's homepage!
 
Old 05-04-2009, 10:31 AM Re: Overlap image outside of div height
MattCoops's Avatar
Ultra Talker

Posts: 423
Name: Matt Cupan
Location: Charlotte, NC
Trades: 0
just left out background color.
it actually works in IE, surprising
thanks (talkupation given)
__________________
Matt - Tweeting
Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE

read my
Please login or register to view this content. Registration is FREE
MattCoops is offline
Reply With Quote
View Public Profile Visit MattCoops's homepage!
 
Reply     « Reply to Overlap image outside of div height
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.24472 seconds with 13 queries