[SOLVED] How to suppress Header from appearing on certain categories?
Hi all,
On my site, I have a page that lists posts from a certain category. My hyperlinks to these posts use "rel=shadowbox" to display the Post in a popup Shadowbox JS - but it looks weird to have the Header,Kicker,Category Bar and Page Bar appearing in these popups, so I'm trying to suppress it. In other words, I'm basically trying to suppress Header,Kicker, and bars for certain categories. To do this, I think I need to add logic to the code seen in Center Column -> Style & edit Center Column -> "The Loop", something like "if Category=XX or YY, then do not process <?php bfa_post_kicker, <?php bfa_post_headline, etc. I have tried hacking around with <?php IF statements based on other posts in this support forum, but I can't get it working. Anyone interested in helping me figure this out? I use Atahualpa 3.4.9 Thanks all... |
I figured it out!!! It's not the Center area that I need to edit after all. It's header.php.
Where it says: Code:
<!-- Header --> Code:
<!-- Header --> So cool! (an Admin can mark this post as Solved...I don't see a way to do it myself...) |
You should be able to do this in The LOOP and there fore not have to remember to do it the next time you upgrade.
To mark a thread solved, use the 'Thread Tools' tab near the top of the page |
Juggledad: can you give some advice about doing this in the Loop? I did try that first, but couldn't find a way. It's really is preferable considering the upgrade issues you mention.
|
to keep part of a post from showing when it is in category 3,
a - go to ATO->Style & edit CENTER COLUMN->The LOOP b - find the part you don't want, like <?php bfa_post_footer('<div class="post-footer">','</div>'); ?> c - change the leading '<?php ' to '<?php if ((!in_category('3') {' d - change the ending from '?>' to ' } ?>' so that HTML Code:
<?php bfa_post_footer('<div class="post-footer">','</div>'); ?> HTML Code:
<?php if ((!in_category('3') { bfa_post_footer('<div class="post-footer">','</div>'); } ?> HTML Code:
<?php bfa_post_byline('<div class="post-byline">','</div>'); ?> HTML Code:
<?php if ((!in_category('3') { bfa_post_byline('<div class="post-byline">','</div>'); } ?> |
in the Loop area I was only able to avoid these settings:
Code:
<?php bfa_post_kicker('<div class="post-kicker">','</div>'); ?> |
Do you mean the page header, ie logo menu header image?
|
Quote:
|
ok, I guess I was a little confused with the description.
If you want to prevent the header area from displaying on a certian PAGE you can use a CSS Insert HTML Code:
body.page-id-xxxx #header {display:none;} For a category page you could use HTML Code:
body.category-xxxx #header {display:none;} |
Thanks again Juggledad. I experimented with that too, but can't get it to eliminate the full page header as I can do by adding the IF logic to header.php. Maybe my solution is not the elegant approach, but it works for me.
Really nice of you to reply and help out, I do appreciate it!! I'll mark this topic as Solved. |
All times are GMT -6. The time now is 08:35 AM. |
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.