How do I remove elements with xuijs?

217 Views Asked by At

I have:

<div class="result">
  <div class="child">
    <h2>afsdf</h2>
    <p>ardyh</p>
  </div>
  <div class="child">
    <h2>....
  ..
  </div>
</div>

and want to replace all in .result with

<p>please wait..</p>

$x('.result').html('remove') does nothing and no method of .html removes the children.

How to to it?

regards, /t

2

There are 2 best solutions below

4
On BEST ANSWER
x$('.result').html('<p>please wait..</p>');

should work according to the documentation of xuijs

0
On

x$('#foo').html('remove');

http://xuijs.com/docs/dom