Nick Cox
Nick Cox

Reputation: 1

Wordpress theming: Wrapping entry titles?

I'm developing a custom child theme for the Thematic Framework.

I'm having trouble with the alignment of my post titles. When they wrap onto a second line, they mess up the positioning of my date.

You can see an example here: http://everydaytype.com/wp

On the top entry, which is one line long, the date and the entry title are aligned.

On the second two following entries, the title wraps to a second line and displaces the date.

I've tried playing with the relative and absolute positioning of both the entry date and the entry title to no avail. I've tried playing with the height and the line height. I've tried display:inline variants.

I'm using Firebug to reveal the CSS that affects both elements, but haven't yet been able to make anything work.

My goal, to state it clearly, is to be able to have entry titles of any length and keep them aligned with the date like on the top entry.

Any ideas would be greatly appreciated.

Upvotes: 0

Views: 568

Answers (1)

you can try to place the <span class="entry-date"> before the <h2> in the html code itself. (in one of your theme files).

<span class="entry-date">...</span>
<h2 class="entry-title">...</h2>

then apply the following styles:

.entry-date {
   clear:both;
   display:block;
   font-family:Futura,sans-serif;
   height:0;
   padding-right:30px;
   position:relative;
   top:2em;
   width:60px;
 }

Upvotes: 1

Related Questions