Use append() method to insert the text "YES!" at the end of the <p> element - Javascript jQuery

Javascript examples for jQuery:Tag Edit

Description

Use append() method to insert the text "YES!" at the end of the <p> element

Demo Code

ResultView the demo in separate window

<!DOCTYPE html>
<html>
<head>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>
<script>
$(document).ready(function(){
    $("p").append("YES!");
});/*from   ww  w  .  j ava2s.  c  o m*/
</script>
</head>
<body>

<p>Is jQuery FUN or what? </p>

</body>
</html>

Related Tutorials