<!DOCTYPE html>
<html>
<head>
<script src="/lib/jquery-1.12.2.min.js"></script>
<script>
$(document).ready(function(){
    $("button").click(function(){
        alert($("p").html());
    });
});
</script>
</head>
<body>

<button>Return the content of the p element</button>

<p>This is a <b>paragraph</b>.</p>

</body>
</html>