1

I don't have access to html, but i want to test something... How would I select the text boomboomboom and hide it with CSS...

the markup looks like this:

<div class="bla">
  <div>
    <strong>some text</strong>
    <br />
    boomboomboom
  </div>
</div>

I tryed this:

.bla div {
  text-indent: -9999px;
}
.bla div strong {
  text-indent: 0px;
}

but this just hides "some text" instead of "boomboomboom"...

can anyone help me? http://jsfiddle.net/b26N7/1/

2 Answers2

3

Check this topic, it's the same thing.

Conclusion is, you can't select the text node with the css at this moment(without wraping it in a html element), but you can do it with JavaScript.

Community
  • 1
  • 1
n1kkou
  • 3,096
  • 2
  • 21
  • 32
-1

Remove <br /> to separate the "boomboomboom" in next line.
You can use "display:block" to show the "boomboomboom" in next line.

Then your css will work properly.

Example: http://jsfiddle.net/uL9Rg/

Rakesh Kumar
  • 2,705
  • 1
  • 19
  • 33