2008-11-10 02:39:03 +00:00
|
|
|
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
|
|
|
|
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
|
|
<html>
|
|
|
|
<head>
|
|
|
|
<meta http-equiv="Content-type" content="text/html; charset=utf-8">
|
|
|
|
<title>body</title>
|
|
|
|
<style type="text/css" media="screen">
|
2012-08-19 19:53:09 +00:00
|
|
|
body { margin: 1px; padding: 5px; position: relative }
|
2008-11-10 02:39:03 +00:00
|
|
|
#marker { position: absolute; border: 2px solid #000; width: 50px; height: 50px; background: #ccc; }
|
2012-08-19 19:53:09 +00:00
|
|
|
#firstElement { width: 50px; height: 50px; background: green; }
|
2008-11-10 02:39:03 +00:00
|
|
|
</style>
|
2013-01-26 15:48:10 +00:00
|
|
|
<script src="../../../dist/jquery.min.js"></script>
|
2008-11-10 02:39:03 +00:00
|
|
|
<script type="text/javascript" charset="utf-8">
|
2011-01-24 03:19:33 +00:00
|
|
|
jQuery(function($) {
|
2008-11-10 02:39:03 +00:00
|
|
|
$('body').click(function() {
|
|
|
|
$('#marker').css( $(this).offset() );
|
|
|
|
return false;
|
|
|
|
});
|
|
|
|
});
|
|
|
|
</script>
|
|
|
|
</head>
|
|
|
|
<body>
|
2012-08-19 19:53:09 +00:00
|
|
|
<div id="firstElement"></div>
|
2008-11-10 02:39:03 +00:00
|
|
|
<div id="marker"></div>
|
|
|
|
</body>
|
2011-01-24 03:19:33 +00:00
|
|
|
</html>
|