- This topic is empty.
-
AuthorPosts
-
August 27, 2013 at 10:35 am #148246
Hplatini89
ParticipantHello World!
I need a bit help, I am developing a custom theme for WordPress: http://bjorn.flabifitness.hu/
I need a fixed header, footer, menu area. And a fluid content area with page content (an image).
During browser window size is changing, only the content need to be changed/adjusted to view-size, without scrollbar, and if the picture is bigger than the browser window, or the monitor, it should be adjusted to the size of browser-window. (fluid)
Header, footer, and menu (vertical position) should be at the same place. (fixed)
This is my CSS-code for now: (main: all of page, inside header, container(sidebar, content), footer)
`main {
position: absolute; background-color:#434343; z-index:0; display: block; opacity: 0; top:0px; left:0px; width:100%; height:100%; text-rendering: optimizeLegibility;
}
header {
background: #1d1d1d; margin: 0; padding-top: 15px; padding-left: 35px; padding-bottom: 13px; min-width: 100%; margin:0px auto;
}
footer {
clear: both; min-width: 100%;
}
/* two columns*/
.container {
height: auto;
overflow: hidden;
}.sidebar {
width: 242px;
float: left;
background: #434343;
min-height: 92%;
}.content {
float: none; /* not needed, just for clarification /
background: #434343;
/ the next props are meant to keep this block independent from the other floated one */
width: auto;
overflow: hidden;
}
`August 28, 2013 at 1:59 am #148324Paulie_D
MemberPerhaps you could put something in Codepen for us to play with.
August 28, 2013 at 3:51 am #148338Hplatini89
ParticipantOk, thanks! :)
so the main point is:
image should be resized only, and other elements should be sticked to the image container.
August 28, 2013 at 4:03 am #148340Paulie_D
MemberIs the image there for Content purposes or Styling?
August 28, 2013 at 4:48 am #148343Hplatini89
Participantfor content purposes, this would be all the content (in content area)
August 28, 2013 at 4:49 am #148344Paulie_D
MemberI stripped out all of the images into the background and I think I’m mostly there.
August 28, 2013 at 4:58 am #148346Paulie_D
MemberI checked, now content area is adjusted by vertical resize.
The image gets smaller as you narrow the window doesn’t it?
You can’t keep the footer at the bottom of the page at all times AND have the image fill the rest of the content area exactly unless it distorts to do so.
August 28, 2013 at 6:14 am #148352Hplatini89
ParticipantYes, your solution is perfect, and I need the same horizontally and vertically together. just like here: http://www.caesarlima.com/
August 28, 2013 at 7:07 am #148363Paulie_D
MemberSo it’s perfect..or isn’t it, I’m confused?
I’m pretty sure you can’t be responsive BOTH ways without distorting the image..unless there is something else going on.
August 29, 2013 at 7:07 am #148498Hplatini89
ParticipantIn this site, can You guess, what they use?:
It is cropping the images, but I cannot extract the appropriate CSS.
-
AuthorPosts
- The forum ‘CSS’ is closed to new topics and replies.