so I'm working on wordpress list posts loop, and i put a post title in div with fixed width and height.. but some posts have a long title, so i want it to be in a smaller font size and less line height, but i can't make a new class for it,
here is what i mean:
<div class="post-title">hellow hellow hellow</div>
<div class="post-title-2">hellow hellow hellow hellow hellow</div>
<style>
.post-title{
width: 100px; height: 25px;
border:1px #000 solid;
font-size: 14px;
}
.post-title-2{
width: 100px; height: 25px;
border:1px #000 solid;
line-height:100%;
font-size: 11px;
}
</style>
and in JSFiddle:
is that possible? and how?