Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $(document).ready(function(){
- $("button").click(function(){
- x = $("p").offset().left; // 表 p 標籤與document x 軸的距離(離左方)
- y = $("p").offset().top; // 表 p 標籤與document y 軸的距離(離上方)
- });
- });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement