HTML for Hiding sidebar on one page?
-
Hello!
I was wondering if there is any simple HTML code I could stick into my sidebar that would allow me to hide text/images/my entire sidebar for one page of my blog. I love my sidebar, and I don’t want to get rid of it completely. I have to wait a bit to pay for the CSS upgrade, so if there is any hide/show code for images and text, I would be over the moon!!
thanks!
Choubelle
The blog I need help with is: (visible only to logged in users)
-
No there is not, and there is no way in the CSS to hide it on one page only either although if there was, I would expect only Sandbox 1.6.1 would have that ability.
-
-
-
Actually, you could easily set something up in your template. In your template, open “page.php” and basically near the bottom there where it’s loading the function “get_sidebar();” just add a conditional statement there to tell it to load or not.
For example. My “contact” page loads with the url:
http://mydomain.com/index.php?page_id=2So when im loading the sidebar function, I tell it to ignore the load if page id = 2.
<?php if ($_GET['page_id'] != 2) get_sidebar(); ?>Simple. Now it loads on every page, but if the page_id in the url is = 2, no load.
Hope that helps..
-
Gak. I see this is for the hosted WordPress only. Color me ignorant I got this thread from a google result so I wasn’t quite sure what the context was. My apologies.
- The topic ‘HTML for Hiding sidebar on one page?’ is closed to new replies.