Empty space between header and main body
cgguido
Registered Users Posts: 18 Big grins
Hi everyone,
Any idea how to change the amount of space between the header and the breadcrum in this page?
http://photo.gcianci.com/Stories
or
http://photo.gcianci.com/Stories/The-Chicago-Blizzard-of-2011/
I cannot figure it out. Using Chrome's dev tools, I thought I had narrowed it down to something like:
.sm-page-layout .sm-page-layout-typetemplate .sm-page-layout-smugtemplate .sm-page-layout-full{
margin: 10px 60px 48px;
}
But that has no effect. :help :
Any help would be much appreciated!
G
Any idea how to change the amount of space between the header and the breadcrum in this page?
http://photo.gcianci.com/Stories
or
http://photo.gcianci.com/Stories/The-Chicago-Blizzard-of-2011/
I cannot figure it out. Using Chrome's dev tools, I thought I had narrowed it down to something like:
.sm-page-layout .sm-page-layout-typetemplate .sm-page-layout-smugtemplate .sm-page-layout-full{
margin: 10px 60px 48px;
}
But that has no effect. :help :
Any help would be much appreciated!
G
--
photo.gcianci.com
photo.gcianci.com
0
Comments
Customize>Galleries>Layout>Top Margin
boom!
G
photo.gcianci.com
I've tried the firebug dev tool and found the string of html that controls that element, but it seems that there is inline css. Can this be overridden through the available CSS feature in the themes tab?
Thanks in advance for any help!
Frank
Excellent question! Using the Firebug Dev Tools is a great way to figure out which code you need to over-ride. You can experiment with the CSS using the tool and then copy the code to place into your theme's CSS section (or in a CSS content block). Just remember to attach "!important" to the end ... this forces it to over-ride. For example:
Should become:
Former SmugMug Product Team
aaron AT aaronmphotography DOT com
Website: http://www.aaronmphotography.com
My SmugMug CSS Customizations website: http://www.aaronmphotography.com/Customizations
And this is what I am trying to use to override it:
<img src="https://us.v-cdn.net/6029383/emoji/headscratch.gif" border="0" alt="" >
My Website index | My Blog
On my homepage, I am trying to configure the top margin of the body element. However, given the constraint by the interface of SmugMug's customization tool, I am only able to adjust said margin by units of pixels but would like to use a percentage (see previous post). Turning to the Firebug dev tool, I have pin-pointed the string of html (again, in previous post) and am trying to override its inline css.
If you give us a link to your site and some more description of what you're trying to do we might be able to help? Typically using %'s for height can lead to some issues as the height of screens tends to vary. 10% of a 1,000 pixels is 100 pixels and an image might fit. But 10% of a 400 pixel screen is only 40 pixels, and you might end up with a really teeny image or it might get cut off.
Former SmugMug Product Team
aaron AT aaronmphotography DOT com
Website: http://www.aaronmphotography.com
My SmugMug CSS Customizations website: http://www.aaronmphotography.com/Customizations
What I would like is for the top margin of the body content block to adjust to the height of the browser window.
http://s21.postimg.org/i59e2bz6f/Screen_Shot_2014_10_29_at_2_52_05_PM.png
Sorry I am still not 100% clear from that photo - are you trying to get that block in the middle of the page with the logo on it up near (or alongside) the header bar? If so, it's not just a matter of dragging on the crosshairs on the little blue tool bar on the block and moving it up closer to the header? Or have I completely misunderstood!
Whilst you can specify margins in %, I'm not sure that won't cause you other issues, as from what I understand it calculates that % based on the width of the container the element is in, so on different browsers/devices you may get unexpected results. But I've never tried it, so can't speak from certainty!
Sam
______________________________
SmugMug site - samuelmcdowell.com
http://postimg.org/image/ldun86gkj/
I am not sure why the code you are trying, after leftquark's suggestion, is not working though. I just tried adding the following into a CSS block on one of my pages and it took effect:
If you look in the inspector afterwards, can you see your code in there?
Also - as leftquark said (and I accidentally repeated) using a % for margins may give unexpected results in different browsers/devices. Are you trying to position that content somewhere in then middle of your page? There may be another way if so.
Sam
______________________________
SmugMug site - samuelmcdowell.com
Thank you Sam, and YES! If I could locate the media queries for the responsive codes, I would have the logo portion (dlrfoto) within the body content block display hidden for both tablet and mobile devices.
But for now, I would like the box showing up the bottom third of all the desktop browsers.
Margin % issue
Media queries for different sized screens
Seeing as your site is not 'public' yet, no-one else can go in and inspect your code. So the more information you can provide about what you are doing/seeing, the better!
EDIT: Had missed out the reference to Screenfly for tips on customising sites for small screens.
Sam
______________________________
SmugMug site - samuelmcdowell.com
Oh so close it feels! hehe
Sorry! That would stop it from working.
I realise that the code I supplied was almost the same as yours (well, now it is corrected...). I see no real reason why mine would work and yours wouldn't - just that I had actually seen my in action so it was a 'known good' from my testing!
Two further thoughts:
1.) Are you sure the code isn't actually working but you just can't tell? I am not sure what the difference would look like between 450px and 25%?? But perhaps you could try varying the number to something more extreme - say 1% or 80% - and then see if you notice a difference.
2.) I have captured the process so maybe you can see more easily where to look for problems. The following is how I added it to the Theme CSS (I have also had it work by adding a CSS block to a specific page):
Before: You can see the small gap above the 'centre' content block, the margin settings in the Layout panel of the customiser bar, the relevant area in the Inspector at bottom of screen and, to the right, where the 24px top margin is currently applied.
http://postimg.org/image/89r3ngy6p/
Code: As entered in the Theme CSS area
http://postimg.org/image/89r3ngy6p/
After: For the same section in the Inspector at the bottom of screen, you can now see the '25%' top margin applied in the settings at right, and the resultant change in spacing above the 'centre' content block on the page.
http://postimg.org/image/lpe4cx6oh/
For the media query stuff, I also had forgotten to add one other tool to the list earlier (I have edited it since) but Screenfly, if you haven't seen it, is extremely useful for testing.
Hopefully this will get you past the finish line!
Sam
______________________________
SmugMug site - samuelmcdowell.com
All sorted on the %age front. Will try to massage the media queries now.
Looked like the specific code needed to be applied to the specific page whereas before, I was trying to achieve this through the Advanced - Edit - CSS settings of my global Customization mode.
Thank you ever so much, Sam! I will now know how to proceed on where to place the codes for the media queries!
Kindest,
Frank
Fantastic! My pleasure Frank. For the media queries - I think that you will probably need to put these in the entire Theme CSS, or else you will have to add them to every page. But a bit of trial and error will get you on the right path. And remember Screenfly!
Sam
______________________________
SmugMug site - samuelmcdowell.com