Forums » Themes and Templates » TwentyTwelve: Putting Post Date only under Post Title?

  • I have a child of TwentyTwelve where i’m trying to put the post date only under the post title on a page. However, if I have a date of 11th December 2013, it’s wide enough to wrap, even though there is plenty of white space to its right.

    Any ideas how to make the Post Title and Post Date (on successive lines) use as much width as they want to within the text width of the post?

    The CSS I have is:

    .entry-date {
            position: absolute;
            top: 24px;
            left: 0;
            visibility: visible;
    }
    
    /* Cut out visibility of all posted elements bar the date itself */
    
    .entry-meta {visibility: hidden;}
    .by-author {visibility: hidden;}
    .entry-date {visibility: visible;}
    .site-content article {position: relative;}
    .site-content {margin-top: 24px; }
    .site-content article {margin-bottom: 24px; padding-bottom: 0px;}
    .site-header  {padding-bottom: 0; }

    The example page is http://www.software-enabled.com/ld1/news – see the spoof post under “Another new title”.

    Any help or guidance would be greatly appreciated.

Viewing 1 replies (of 1 total)
  • Thread Starter IanWaring

    (@ianwaring)

    Seems to just be a problem on Chrome on my Chromebook; there is an inexplicable width restriction to 117 pixels wide on the date text. Hence i’ve elected to leave the date in the content footer where twentytwelve was designed to accommodate it.

    Without the absolute position, the default “This entry was posted in uncategorized on DD-MMM-YYYY by Author.” along with the .entry meta with visibility hidden and .entry-date visible is just leaving the date camped around 2/3 across the width of the panel; I guess as the space is still reserved for the preceding text fields even if not used.

    I’m not yet clever enough with CSS to tell the .entry-date to be forced to the left margin, or even better to center in the column, despite the other hidden fields sitting in that space. If anyone can give me a pointer, it would be greatly appreciated.

Viewing 1 replies (of 1 total)
  • The topic ‘TwentyTwelve: Putting Post Date only under Post Title?’ is closed to new replies.