Đăng nhập
Latest topics
» Tôi sẽ đỗ đại học!by nightWalker 9/2/2024, 7:00 pm
» Kỷ niệm xưa của chúng ta
by nightWalker 9/2/2024, 6:49 pm
» Bị lệch khung cần người giúp đỡ
by webhuy28 7/10/2021, 10:34 pm
» [HỎI ĐÁP] Danh sách bạn bè không thể hiển thị
by anhdaodaica1 2/10/2021, 10:04 pm
» [HỎI ĐÁP] Thông tin tài khoản không thể lưu thay đổi
by anhdaodaica1 2/10/2021, 6:05 am
» Phim bố già full
by huy.pc52 24/8/2021, 12:20 am
» Xin code Box HTML cho Forumvi
by Larva 1/7/2021, 12:57 pm
» Hello Anh Em Chinh phục
by HoàngTửNaivip5p 28/5/2021, 5:03 am
» Trang chủ tin tức cập nhật HOT 2016
by kenbi05 1/1/2020, 11:02 pm
» Không Dang9 bài viết = hình ảnh được
by huy.pc52 30/11/2019, 10:52 am
» CHÚC ANH EM NĂM MỚI VUI VẺ TRÀNG ĐẦY HẠNH PHÚC
by sps.kủn 12/2/2019, 1:16 pm
» Skin CNTT-K3 2015 (Full Mod)[✔]
by kenbi05 6/7/2018, 12:30 am
» baivong, handsome,....
by sps.kủn 29/6/2018, 1:54 pm
» [SHARE] SKIN ĐHFM.V7 @PUNBB
by tonyhoaivu 2/5/2018, 2:37 pm
» Share Skin Xanh Dương Cùi Bắp
by tonyhoaivu 28/4/2018, 5:57 pm
» Xin Skin http://v1.hotrofm.net/
by tonyhoaivu 28/4/2018, 5:45 pm
» Xin Skin Rao Vặt
by tonyhoaivu 15/4/2018, 12:07 pm
» Làm Sao Để Xóa Khung Này
by tonyhoaivu 14/4/2018, 7:18 pm
» [Lập nhóm]Lập nhóm fm
by vietkanpy 31/3/2018, 11:53 am
» [Help] về server úp ảnh của phutu [✔]
by baivong 17/3/2018, 10:18 pm
» Đừng khóc cho “tôi – Chinh Phục!”…
by AnHung 27/2/2018, 5:33 pm
» [Share] Skin Diendandaihoc.com [ Punbb ] [✔]
by Lu Mờ 13/2/2018, 7:28 pm
» Mời mấy thím vào groups Forumotion Việt Nam.
by dang02315 13/2/2018, 12:40 am
» Có thể làm các kiểu giao diện được không?
by Lu Mờ 9/2/2018, 3:40 pm
» ltns chinhphuc.info
by Shinichi Kudo 27/1/2018, 2:27 am
Top posting users this week
No user |
[Javascript] Ông già Noel bay lượng trong forum[~]
2 posters
Trang 1 trong tổng số 1 trang
[Javascript] Ông già Noel bay lượng trong forum[~]
demo : http://vietgame.123.st/h5-page
Code này Rip của 1 trang DJ nhé !
Hướng dẫn:
ACP >>Modules >>HTML & JAVASCRIPT >>Javascript codes management >>Create a new javascript
Title * : Noel ( tùy bạn )
Placement : In all the pages
Javascript Code * : Cho code bên dưới vào
Code này Rip của 1 trang DJ nhé !
Hướng dẫn:
ACP >>Modules >>HTML & JAVASCRIPT >>Javascript codes management >>Create a new javascript
Title * : Noel ( tùy bạn )
Placement : In all the pages
Javascript Code * : Cho code bên dưới vào
- Code:
var Ghost=function(){var b={};if($.browser.msie){if($.browser.version<8){return b}}b.html='<div class="ghost"></div>';b.element=null;b.timer=null;b.interval=Math.floor(Math.random()*1000)+1000;b.directionX=Math.round(Math.random());b.directionY=Math.round(Math.random());if(b.directionX==0){b.directionX=-1}if(b.directionY==0){b.directionY=-1}b.screenWidth=null;b.screenHeight=null;b.elementWidth=150;b.elementHeight=145;b.init=function(){b.getBrowserSize();$(window).resize(function(){b.getBrowserSize()});b.element=$(b.html);b.timer=window.setInterval(b.move,b.interval);$("body").append(b.element);b.move(true);b.move();return b};b.move=function(t){var s=Math.floor(Math.random()*100+100);var r=Math.floor(Math.random()*100+100);var q=b.element.offset().left;var p=b.element.offset().top;var o=q+b.directionX*s;var n=p+b.directionY*r;var m=b.screenWidth-b.elementWidth-20;var l=b.screenHeight-b.elementHeight;if(o>m){o=m;b.directionX=-b.directionX}else{if(o<0){o=0;b.directionX=-b.directionX}}if(n>l){n=l;b.directionY=-b.directionY}else{if(n<0){n=0;b.directionY=-b.directionY}}var a=Math.random()-0.1;if(a<0.4){a=0.4}if(t){b.element.css("top",Math.floor(Math.random()*b.screenHeight-b.elementHeight));b.element.css("left",Math.floor(Math.random()*b.screenWidth-b.elementWidth))}else{b.element.removeClass("moving-left");b.element.removeClass("moving-right");if(o>q){b.element.addClass("moving-right")}else{if(o<q){b.element.addClass("moving-left")}}b.element.stop();b.element.animate({top:n,left:o,opacity:a},{duration:b.interval,easing:"swing"})}};b.getBrowserSize=function(){b.screenWidth=$(document).width();b.screenHeight=$(document).height()};b.init();return b};$(function(){$("body").append("<style>.ghost{position:absolute;width:200px;height:200px;z-index:999999991;display:block;opacity:0.8;background:transparent url(http://i57.servimg.com/u/f57/16/18/15/10/vietga10.png) no-repeat}.ghost.moving-left{-moz-transform:scaleX(-1);-webkit-transform:scaleX(-1);-o-transform:scaleX(-1);transform:scaleX(-1);filter:fliph}</style>");var b=new Array();for(var a=0;a<1;a++){b.push(new Ghost())}});
Được sửa bởi An Nguyễn ngày 23/12/2013, 10:04 pm; sửa lần 1.
Similar topics
» [Share] Ông già noel cưỡi tuần lộc, bay khắp...forum
» Trang trí forum noel (đã sửa lại)[✔]
» Trang trí forum noel[✔]
» Bộ nút tăng giảm cỡ chữ trong website bằng javascript
» [Chia sẻ] Một số effect giành cho forumotion trong dịp NOEL.
» Trang trí forum noel (đã sửa lại)[✔]
» Trang trí forum noel[✔]
» Bộ nút tăng giảm cỡ chữ trong website bằng javascript
» [Chia sẻ] Một số effect giành cho forumotion trong dịp NOEL.
Trang 1 trong tổng số 1 trang
Permissions in this forum:
Bạn không có quyền trả lời bài viết
|
|