Skip welcome & menu and move to editor
Welcome to JS Bin
Load cached copy from
 
<table>
  <tr>
    <td>
       <a class="link-wrap" href="#">
         <span class="link">Foo</span>
       </a>
    </td>
   <td>Bar<br>Baz</td>
  </tr>
</table>
 
table {
  border-collapse: collapse;
}
  
td {
  border: 1px solid #ddd;
  height: 100%
}
  
.link-wrap {
  height: 100%;
  display: table;
}
  
.link {
  display: table-cell;
  vertical-align: middle;
  background: #afa;
}
Output 300px

This bin was created anonymously and its free preview time has expired (learn why). — Get a free unrestricted account

Dismiss x
public
Bin info
anonymouspro
0viewers