mmistakes / jekyll-theme-skinny-bones

A Jekyll starter with a variety of flexible layouts and components.
https://mmistakes.github.io/jekyll-theme-skinny-bones
MIT License
802 stars 907 forks source link

Globally remove advertisements from all pages #19

Closed ekstroem closed 9 years ago

ekstroem commented 9 years ago

Hi,

Is is possible to remove the advertisements globally from all pages (e.g., posts) in order to user the full screen. I tried entering ads: false as shown below in _config.ymlbut it doesn't seem to have the desired effect.

# Site owner
owner:
  name: 
  email: 
  twitter: 
  google:
    ad-client: 
    ad-slot: 
    ads: false
  bio: 
  avatar: bio-photo.jpg # 160x160 px image for author byline
mmistakes commented 9 years ago

Yes it is. You need to modify the CSS as well. The main content container is set to span 9 out of 12 columns leaving 3 columns worth of space for ads (or anything else you'd like to stick in as a sidebar).

If you in change 9 to 12 in _layout.scss it should span the full width of the parent container.

#main {
    .inner-wrap {
        @include media($medium) {
            @include span-columns(12); // change 9 to 12
        }
    }
}

You might want to permanently remove {% if page.ads == true %}<div class="ads">{% include advertising.html %}</div><!-- /.ads -->{% endif %} from each of the _layouts as well just to make sure ads aren't ever displayed, which would likely break the layout once you widen #main div.inner-wrap.

ekstroem commented 9 years ago

Cheers,

Got it up and running as desired. Thank you for making this available!