• Resolved ruewa

    (@ruewa)


    Hi,

    I’d like to get rid of the sidebar and go to full content width only in single post pages. Could only find all-page-solutions for Iconic One and lots of solutions for other themes which do not match Iconic theme.

    I removed the line
    <?php get_sidebar(); ?>
    in single.php, but there remains the sidebar frame.

    Adding

    .site-content {
        width: 96%;
    }

    in custom.css would turn all pages to full width. How could full width content be restricted to single posts only?

    In addition to this: Can I set padding in order to display the text between 10% and 90% of the width in full width mode? Again for single posts only?

Viewing 2 replies - 1 through 2 (of 2 total)
  • Thread Starter ruewa

    (@ruewa)

    Maybe my question wasn’t clear enough. For me as an (aged &) old-fashioned Pascal fan this php-css-stuff seems to be too far away from my modes of comprehension – I really can’t find the screw.

    What I try to find out is how to link the condition of is_single (which is true inside of single.php) to the site-contents width (defined in custom.css). Or let me put it in Pascal terms:

    If is_single then
    site-content.width := 96 % // dont’t get_sidebar
    else
    begin
    site-content.width := 66 %;
    get_sidebar;
    end;

    There are lots of solutions documented for several themes, but apparently they don’t match the structure of Iconic One. Is this really such hard stuff?

    Thread Starter ruewa

    (@ruewa)

    Okay, got it.

    I removed the get_sidebar line in single.php and added this after get_header:

    <style type="text/css">
    	.site-content {
     		width: 96%;
    	}
    	@media screen and (min-width: 960px) {
    		.site-content {
     			width: 77%;
    			margin: 0px 10%;
    			border-right: 0px solid #F1F1F1;
    		}
    	}
    </style>

    I don’t know whether this is a good or an ugly approach (warn me, if that’s a bad idea), but it seems to work the way I want.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘[Theme: Iconic One] How to get full width content in single post only’ is closed to new replies.