<script src="_scripts/jquery-1.4.1.min.js" type="text/javascript"></script>
<script type="text/javascript">
$(function() {
$("#dvHTMLStripped").html($("#dvHTML").text());
$("#dvHTMLEncoded").text($("#dvHTML").html());
$("#dvHTMLDecoded").html($("#dvHTMLEncoded").text());
});
</script>
</head>
<body>
<form id="form1" runat="server">
<div>
<b>Source:</b>
<div id="dvHTML"> <small>This</small> is <b>jQuery Sample.</b></div>
<br />
<b>HTML Stripped:</b> <div id="dvHTMLStripped"></div>
<b>HTML Encoded:</b> <div id="dvHTMLEncoded"></div>
<b>HTML Decoded:</b> <div id="dvHTMLDecoded"></div>
</div>
</form>