HTML / CSS Ellipsis (...) Not Working

css, ellipsis, html, overflow, text

Solution

Based on the initial post, we're all assuming the obvious, but just in case ... ;)

<style type="text/css">
    .oneline {
        text-overflow : ellipsis;
        white-space   : nowrap;
        width         : 50px;
        overflow      : hidden;
    }
</style>
<div class="oneline">Testing 123 Testing 456 Testing 789</div>

http://jsfiddle.net/NawcT/

EDIT: Solution was to style the paragraph vs the div.

Problem

I'm attempting to get ellipsis working on my site. This is the following HTML / CSS code and it doesn't appear to be working. CSS: ``` .oneline { text-overflow:ellipsis; white-space: nowrap; width: 50px; overflow: hidden; } ``` HTML: ``` <div class="oneline">Testing 123 Testing 456 Testing 789</div> ```

Original source

Related problems