• Resolved kokojumbo

    (@kokojumbo)


    On the blog page I moved the .entry-footer to the top of the .entry-content. (I changed a php file)

    I would like to place the contents of the .entry-footer (the meta info) in a single line.

    My problem is that beyond the width of 1231px (originally given in “em”) the contents are automatically ordered one above the other – that is, not in a line – and I can’t change it. (In the style.css “@media screen” cannot be modified on its own but only in relation with a couple of other parametres.)

    Please give me your suggestions. Many thanks!

    https://s27.postimg.org/cf46bf5o3/width_1231px.png
    https://s27.postimg.org/abtr3r5v7/width_1232px.png

Viewing 7 replies - 1 through 7 (of 7 total)
  • Besides setting entry-content width to 100% as you already have:

    @media screen and (min-width: 61.5625em) {
    body:not(.search-results) article:not(.type-page) .entry-content {
    	width: 100% !important;
    }

    You need to set entry-footer width to 100% also:

    body:not(.search-results) article:not(.type-page) .entry-footer {
        float: left;
        margin-top: 0.1538461538em;
        width: 100%;
    }

    then set this one to “inline” to show the “/” as divider between the footer content:

    body:not(.search-results) article:not(.type-page) .entry-footer > span:not(:first-child):before {
    	display: inline;
    }

    And finally set this one to “inline-block”

    .single .byline,
    .full-size-link,
    body:not(.search-results).group-blog .byline,
    body:not(.search-results) .entry-format,
    body:not(.search-results) .cat-links,
    body:not(.search-results) .tags-links,
    body:not(.search-results) article:not(.sticky) .posted-on,
    body:not(.search-results) article:not(.type-page) .comments-link,
    body:not(.search-results) article:not(.type-page) .entry-footer .edit-link {
    	display: inline-block;
    	margin-bottom: 0.5384615385em;
    }

    That seems to do the trick! ??

    Thread Starter kokojumbo

    (@kokojumbo)

    Very good job! ?? Functions perfectly!
    Many Thanx Erik!

    This is what I was looking for as well, however I have 3 more questions:

    1) why is the author shown on the full article, but not on the excerp?
    2) is it possible to hide/remove the tags en categories from this line of meta information (probably it is, but how)?
    3) is it possible to add text (like “posted on” of “posted by”)?

    I have seen some of this questions inother posts in this forum but with answers that worked. At least not when placing it in-line, under the content like Erik is explaining.

    thanks in advance,
    Bas

    kokojumbo Could you tell me how you got the .entry-footer to the top of .entry-content? What’s the best way to do this using a child theme? Thanks!

    Thread Starter kokojumbo

    (@kokojumbo)

    Hello kpowed,
    Change this file: twentysixteen – template-parts – content.php.

    https://s14.postimg.org/x6ucti54x/bel.png

    prav201

    (@prav201)

    I tried this solution but all these links at bottom are not seperated by “/” but close to each other. How can I put “/” in between the various items.

    Thanks

    @erik_hansen suggested this:

    body:not(.search-results) article:not(.type-page) .entry-footer > span:not(:first-child):before {
    	display: inline;
    }

    However that didn’t work for me either.

    I found the solution though. This is the code I’ve added in the end and that works for me (also using answers above from @erik_hansen):

    @media screen and (min-width: 61.5625em) {
        
        /*  Revert settings from the parent theme. 
            We always want footer information at the bottom and not on the left if
            we have a wider screen. 
         */
        
        body:not(.search-results) article:not(.type-page) .entry-content {
    		width: 100%;
    	}
        
        body:not(.search-results) article:not(.type-page) .entry-footer {
    		/*float: left;*/
    		/* margin-top: 0.1538461538em; */
    		/*width: 21.42857143%; */
            margin-top: 2.1538461538em;
            width: 100%; 
    	}
        
        body:not(.search-results) article:not(.type-page) .entry-footer > span:not(:last-child):after {
    		/*display: none;*/
            display: inline-block;
    	}
        
        .single .byline,
        .full-size-link,
        body:not(.search-results).group-blog .byline,
        body:not(.search-results) .entry-format,
        body:not(.search-results) .cat-links,
        body:not(.search-results) .tags-links,
        body:not(.search-results) article:not(.sticky) .posted-on,
        body:not(.search-results) article:not(.type-page) .comments-link,
        body:not(.search-results) article:not(.type-page) .entry-footer .edit-link {
            display: inline-block;
            margin-bottom: 0.5384615385em;
        }
        
    }
     
Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘.entry-footer placement in one line’ is closed to new replies.