Side navigation
Ticket #4019: test-case-1.html
File test-case-1.html, 0.9 KB (added by Maaack, January 29, 2009 02:21AM UTC)
Example with alerts to show the result of html() on each object.
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>Test-Case-1
</title>
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
<script src="js/jquery-1.3.1.min.js" type="text/javascript">
</script>
<script type="text/javascript">
$(document).ready(function(){
var htmlobject = $("html");
var html = htmlobject.html();
alert("body = "+$("body",html).html());
alert("body = "+$("body",htmlobject).html());
alert("form = "+$("form",html).html());
alert("form = "+$("form",htmlobject).html());
alert("div = "+$("div",html).html());
alert("div = "+$("div",htmlobject).html());
});
</script>
</head>
<body>
<div class="content">1st<form id="formid" name="formname" action="./user.php?some=1">Form information
</form>
</div>
<div>2nd</div>
<div>3rd<div>4th</div></div>
</body>
</html>
Download in other formats:
Original Format
File test-case-1.html, 0.9 KB (added by Maaack, January 29, 2009 02:21AM UTC)
Example with alerts to show the result of html() on each object.
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>Test-Case-1
</title>
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
<script src="js/jquery-1.3.1.min.js" type="text/javascript">
</script>
<script type="text/javascript">
$(document).ready(function(){
var htmlobject = $("html");
var html = htmlobject.html();
alert("body = "+$("body",html).html());
alert("body = "+$("body",htmlobject).html());
alert("form = "+$("form",html).html());
alert("form = "+$("form",htmlobject).html());
alert("div = "+$("div",html).html());
alert("div = "+$("div",htmlobject).html());
});
</script>
</head>
<body>
<div class="content">1st<form id="formid" name="formname" action="./user.php?some=1">Form information
</form>
</div>
<div>2nd</div>
<div>3rd<div>4th</div></div>
</body>
</html>