On a div I have css set:

```
div.class {border: 1px solid red;}

```

The div is positioned absolutely in the center of the page. The problem is that the border appears even if there is no content. 

Any css methods to get the border to not appear if there is no content?