ThemeShaper Forums » Thematic

[closed]

Autofocus (child theme) custom post template

(7 posts)
  • Started 2 years ago by tobias.snall
  • Latest reply from helgatheviking
  • This topic is not resolved
  1. tobias.snall
    Member

    Hi,

    I have the same exakt problem as the guy who posted this http://forums.themeshaper.com/topic/autofocus-pro-help#post-13038

    I want a to expand the content area for a single post to be fullpage. (removing the sidebar). I would also like to remove everything else below the content of the post (comments etc...)

    I've installed the custom post template plugin. But i need help with actual coding. How do I remove these objects?

    Maybe helgatheviking can help me with this one since she were involved in the other post.

    Posted 2 years ago #
  2. tobias.snall
    Member

    To clarify,

    I've read this post http://programming.thematic4you.com/2010/01/how-to-remove-the-sidebar-from-a-certain-page/

    But i want to remote it from my entire website. And i just can't get it to work.

    Could anyone paste the code and where to put it? I would be truly thankful.

    /T

    Posted 2 years ago #
  3. don't hhave time now to check into the old post or what i wrote there. but if you want to kill the sidebar across the whole site then you simply don't use the conditional logic that chris wrote at programming.thematic4you.com

    Posted 2 years ago #
  4. tobias.snall
    Member

    I guess you are referring to this code snippet

    function remove_sidebar() {
    if (!is_page('whatever')) {
    return FALSE;
    } else {
    return TRUE;
    }
    }
    add_filter('thematic_sidebar', 'remove_sidebar');

    What do I remove and where do i place it? (I've tried placing it in functions.php, but that doesn't seem to do the trick)

    Posted 2 years ago #
  5. yes and yes it goes in your child theme's (so autofocus i guess) functions.php. and 'not working' possibly means that autofocus also is filtering the thematic sidebar OR rather likely, you don't have a page called 'whatever' where the sidebar would actually be OFF so it is always ON.

    "logic" is just a fancy way of saying IF statements (IF/ELSE and also FOR, or WHILE)

    wordpress conditional tags:
    http://codex.wordpress.org/Conditional_Tags

    so removing the conditional logic:

    function remove_sidebar() {
       return FALSE;
    }
    add_filter('thematic_sidebar', 'remove_sidebar');

    just trying to encourage to learn a little something about the process. otherwise you are likely to ask the same things over and over.

    Posted 2 years ago #
  6. tobias.snall
    Member

    I get that 'whatever' refers to a page, hence i renamed it. Tried your solution aswell, nothing will do the trick. I actually manage to figure out that code by myself, but since it didn't work I just assumed i were wrong. I'm not a coder and I don't really get PHP yet, I'm a designer who really like problem solving. I usually manage to figure out HTML and CSS by myself but this is just to complex for me. I'm glad you were willing too help out though.

    /T

    Posted 2 years ago #
  7. not familiar enough w/ autofocus to help further. what i posted earlier WILL kill the default sidebar in any child theme. so if you still have a sidebar it might be something that autofocus is creating.

    also, the php function will not magically change your css to make the pages full width.

    Posted 2 years ago #

RSS feed for this topic

Topic Closed

This topic has been closed to new replies.