Fullwidth page fix and theme options update. #197

Closed
wants to merge 3 commits into
from

Conversation

Projects
None yet
4 participants
Contributor

johnnypeck commented Dec 17, 2011

Fix the full page width issue, adds a theme option for the class and sets some sensible defaults for the various frameworks on that option.

Contributor

johnnypeck commented Dec 17, 2011

I accidentally included a deactivation hook in roots-options.php which I had intended to remove. It wouldn't really hurt anything and may even alleviate a few headaches for some but it could just be superfluous. Let me know and I'll fix and re-pull if needed.

Owner

swalkinshaw commented Dec 17, 2011

Could you remove the deactivation hook? We should consider it separately if it has some benefits. Don't want that change to get lost in this one. Otherwise, pull request looks like a needed solution.

Contributor

johnnypeck commented Dec 18, 2011

I removed the deactivation hook. It's really only useful to make sure options are rebuilt when a change is made during development. Cheers.

Owner

retlehs commented Dec 29, 2011

thanks @johnnypeck - i would have pulled this in already but now i'm rethinking including the full width template. do you think it's worth it to keep it?

Contributor

johnnypeck commented Dec 29, 2011

@retlehs I think it makes sense to have the full width. It's a very common use case and if anything shows an example full width layout to start with for a child theme to implement.

Owner

retlehs commented Jan 2, 2012

one last thing: in the options the label is called '#fullwidth CSS Classes'

it's just a class on the #main ID so a better label might be something like 'Full Width CSS Classes'

once that's updated i'll pull this in, thx @johnnypeck

Contributor

johnnypeck commented Jan 3, 2012

@retlehs No worries. Good call on the option naming. Have a good one.

I went ahead and tried to implement this code and noticed this with 960.gs:

When I created a new page with the Full Width Template in 960.gs, I successfully saw the grid_12 class appear.

However, when I made it the static "Front Page" in the WordPress "Reading" settings, the sidebar div reappeared.

I figured it was a front-page.php deal and changed $roots-options to fullwidth_class in the file. This worked for my use with the theme, but perhaps there's a way to conditionally load this class if full-width is selected.

If I figure something out I'll add a pull request.

Thanks a lot @johnnypeck and @retlehs!

Contributor

johnnypeck commented Jan 8, 2012

@aboutaaron WordPress automatically uses front-page.php if it is present in a theme when you select a static home page. If it was not present in roots then you could use any template you like.

Contributor

johnnypeck commented Jan 8, 2012

@retlehs Any word on getting this pull merged?

@retlehs retlehs added a commit that referenced this pull request Jan 8, 2012

@retlehs retlehs fixes #166, #196 and #197 - adding full width option and applying in
full width template, thx @johnnypeck!
9da422e
Owner

retlehs commented Jan 8, 2012

done with 9da422e, thx @johnnypeck

retlehs closed this Jan 8, 2012

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment