jquery delete buton
$( ".hello" ).remove();
$( ".class" ).remove();
$( "#id" ).remove();
$( "div" ).remove();<div class="container">
<div class="goodbye">Goodbye</div>
</div>
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>remove demo</title>
<style>
p {
background: yellow;
margin: 6px 0;
}
</style>
<script src="https://code.jquery.com/jquery-3.5.0.js"></script>
</head>
<body>
<p>Hello</p>
how are
<p>you?</p>
<button>Call remove() on paragraphs</button>
<script>
$( "button" ).click(function() {
$( "p" ).remove();
});
</script>
</body>
</html>
Also in JavaScript:
- handleClick react
- time stamp to date js
- stop a video jquery
- node js interview questions
- jquery test div exists
- increase node heap size
- url_for javascipt
- go to new page javascript
- explain js es6
- js if char in string
- tays javascript answer test
- google apps script properties service
- nodejs copy and rename file
- use thymeleaf variable in javascript
- jquery multiple div click
- filereader check file type
- pass header in axios
- jalali moment get milisocnds
- refresh javascript
- check if number appears odd number of times in array javascript
- array chunk javascript
- react/redux reducers sintaxe
- how to make a rectangle in javascript
- null is object in javascript