Answers for "jquery wrapp elemetn with tag"

0

jquery wrapp elemetn with tag

<!doctype html>
<html lang="en">
<head>
  <meta charset="utf-8">
  <title>wrap demo</title>
  <style>
  div {
    border: 2px solid blue;
  }
  p {
    background: yellow;
    margin: 4px;
  }
  </style>
  <script src="https://code.jquery.com/jquery-3.5.0.js"></script>
</head>
<body>
 
<p>Hello</p>
<p>cruel</p>
<p>World</p>
 
<script>
$( "p" ).wrap( "<div></div>" );
</script>
 
</body>
</html>
Posted by: Guest on August-01-2021

Code answers related to "Javascript"

Browse Popular Code Answers by Language