Skip to main content

Bug Tracker

Side navigation

Ticket #4268: before.html


File before.html, 0.7 KB (added by tr4nslator, February 27, 2009 07:17PM UTC)

File pointing to original jQuery

<html>
	<head>
		<title>iframe window test</title>
		<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
		<script type="text/javascript" src="jquery-1.3.2.js"></script>
		<script type="text/javascript">
		
			$( function() {
			
				var iframeWindow = $("iframe")[0].contentWindow;
				iframeWindow.name = "iframeWindow";
				window.name = "window";
			
				$([ iframeWindow, window ]).each( function() {
					var name = this.name;
					$( this ).resize( function() {
						$("<p/>")
							.text( "This should be appended to " + name )
							.appendTo( this.document.body );
					})
				})
			})
		
		</script>
	</head>
	<body>
		<p>Resize this window to test.</p>
		<iframe style='width: 100%'></iframe>
	</body>
</html>

Download in other formats:

Original Format