Community Forums › Forums › Archived Forums › Design Tips and Tricks › News Pro – Remove Primary Sidebar
- This topic has 9 replies, 3 voices, and was last updated 10 years, 6 months ago by Tonya.
-
AuthorPosts
-
June 30, 2014 at 3:02 pm #112188dfwcardMember
I have tried everything to remove the primary sidebar. I've tried what CarrieDils posted as it related to the Education theme. I tried srikat's github code for the function.php. I've tried whatever I found under the search Remove Primary Sidebar.
On the home page and the Theme Settings default as well, I have the layout with no sidebars.
The sandbox I have it in is http://summersanta.i8it.com/
http://summersanta.i8it.com/June 30, 2014 at 3:08 pm #112195jodzeeeMemberI think you just need to change the content width in the CSS.
June 30, 2014 at 3:33 pm #112204dfwcardMemberI tried that. It didn't work. It also didn't give me the full page. The primary side bar is still eating up real estate. I am trying to use the full page width.
June 30, 2014 at 4:09 pm #112211jodzeeeMemberIf I change the content width in Chrome's inspector to 100%, it fills the widget area.
Also, in the <body> tag, it says it's using the content-sidebar, not full width. If you're sure you've changed it, maybe there's a caching issue?
June 30, 2014 at 4:19 pm #112215jodzeeeMemberJust read Carrie's solution ... no reason that shouldn't work. But since you're only trying to hide one sidebar and not keep another as she was doing - all you should need to do is choose the full width layout.
June 30, 2014 at 4:44 pm #112233dfwcardMemberI created the css style (Carrie's post) and put the code in the style.css.
One of the lines is .special-page #sidebar {display: none;} Nothing. So I tried sidebar-primary instead of just sidebar. Still nothing.
I believe that it is the newer version of the template built on HTML5. She wrote the article in 2012. Then, most of the templates had a home.php. Now it is front-page.php. I run into issues between the old and new style child themes. This one is kicking my butt.
Just to make sure, I installed a fresh News Pro. No plug-ins. Tried Carrie's suggestion. No go.
June 30, 2014 at 4:56 pm #112238jodzeeeMemberI'm assuming the reason the CSS not working is because of a caching issue.
But let's back up. I assume you're using a static page for your home page? And the page you have defined ... have you set it to use the full-width layout? That's all you should need to do and not mess with the CSS. Carrie's tutorial was to hide one sidebar, but show the other. My understanding is you just want full-width with no sidebar. Just use the layout option.
June 30, 2014 at 5:05 pm #112242TonyaMemberGo into your front-page.php file. Look and see if the page is being forced to content-sidebar via the following line of code:
//* Force Content-Sidebar Layout add_filter( 'genesis_site_layout', '__genesis_return_content_sidebar' );
What you want is this line instead, which forces full width:
//* Force full width content layout add_filter( 'genesis_site_layout', '__genesis_return_full_width_content' );
Software & Electrical Engineer and Programming Teacher · I’m on a mission to help developers be more awesome.
Find Me: KnowTheCode.io | @hellofromTonya | Profitable WordPress Developer BootcampJuly 1, 2014 at 7:08 am #112398dfwcardMemberPerfect! I had added that line at the top, but there was an existing line below it. It worked perfectly! Thank you so much!
Jon
July 1, 2014 at 12:13 pm #112476TonyaMemberWonderful. Glad it helped, Jon. If would be so kind, please mark this issue as Resolved.
Enjoy your day 🙂
Software & Electrical Engineer and Programming Teacher · I’m on a mission to help developers be more awesome.
Find Me: KnowTheCode.io | @hellofromTonya | Profitable WordPress Developer Bootcamp -
AuthorPosts
- The forum ‘Design Tips and Tricks’ is closed to new topics and replies.