GMgKe586q6suSQnyqZLlGCooeWM

Pages

Search

Thursday, March 17, 2011

jQuery - Manipulating DOM

it's easy to do manipulating DOM using jQuery althought it's not compatible with the native DOM manipulation.
To insert content, use
before - insert outside before the selector
after - insert outside after the selector
append - insert in the inside but the last one
prepend - insert in the inside but the first one
detach - remove the selector as well as its content
empty - remove the all the child inside the selector
remove - remove the selector as well as its event and data.
insertAfter - insert content after the target
insertBefore - insert content before the target
Share/Bookmark

1 comment:

  1. how to manipulating DOM with selector?
    can you help me?

    ReplyDelete