jQuery addBack() method
The selector mentioned in the above syntax is the optional parameter of the addBack() method. It specifies a string that contains a selector expression to match the elements against.
Let's understand the working of the addBack() method using an illustration.
In this example we are applying the addBack() method to the paragraph element with id = "p1". Here, we are also using the nextAll() method to select the next paragraph siblings of the paragraph element with id = "p1".Test it Now
After clicking the given button, the output will be -
JavaTpoint offers too many high quality services. Mail us on [email protected], to get more information about given services.
JavaTpoint offers college campus training on Core Java, Advance Java, .Net, Android, Hadoop, PHP, Web Technology and Python. Please mail your requirement at [email protected]
Duration: 1 week to 2 week