Advertisement
Guest User

Untitled

a guest
Apr 21st, 2019
119
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 4.76 KB | None | 0 0
  1. <script src="https://cdnjs.cloudflare.com/ajax/libs/clipboard.js/1.5.12/clipboard.min.js"></script>
  2. <div id="loading__main">
  3. <img id="loading__img" src="https://www.tsunami.gov/images/loader.gif" alt="Loading..." />
  4. </div>
  5. <header>
  6. <div class="navigation__bar">
  7. <ul>
  8. <li><a href="/home"><i class="fa fa-home"></i> Home</a></li>
  9. <li><a href="/forum"><i class="fa fa-pencil"></i> Forum</a></li>
  10. <li><a href="/shop"><i class="fa fa-shopping-cart"></i> Winkel</a></li>
  11. <li><a href="/vote"><i class="fa fa-user"></i> Voten</a></li>
  12. <li><a href="/vote"><i class="fa fa-user"></i> Dynmap</a></li>
  13. <li class="dropdown">
  14. <a href="#"><i class="fa fa-question-circle"></i> Leden</a>
  15. <ul>
  16. <li><a href="/home"><i class="fa fa-info-circle"></i> Staff team</a></li>
  17. <li><a href="/members"><i class="fa fa-question-circle"></i> Leden</a></li>
  18. </ul>
  19. </li>
  20. <li class="dropdown">
  21. <a href="#"><i class="fa fa-question-circle"></i> Meer</a>
  22. <ul>
  23. <li><a href="/regels"><i class="fa fa-info-circle"></i> Regels</a></li>
  24. <li><a href="/solliciteren"><i class="fa fa-question-circle"></i> Soliciteeren</a></li>
  25. <li><a href="/home"><i class="fa fa-book"></i> Feedback/a></li>
  26. </ul>
  27. </li>
  28. </ul>
  29. </div>
  30. <div class="middle__bar">
  31. <div class="logo__main">
  32. <img src="https://i.imgur.com/dCBxcvw.png" />
  33. </div>
  34. <div class="server__box_wrap">
  35. <div id="player__heads" class="box" style="display:inline-block;position: absolute;margin-left: 15%;">
  36. <div class="player__list"></div>
  37. </div>
  38. <div class="server__box">
  39. <div class="players"><span id="online"></span> Spelers Online</div>
  40. </div>
  41. <div class="server__box">
  42. <div id="ip" data-clipboard-text="mc.dreamsurvival.nl">mc.dreamsurvival.nl</div>
  43. <div class="click__copy">klik om te kopieren!</div>
  44. </div>
  45. </div>
  46. </div>
  47. <a href="#" class="scroll__top"><i class="fa fa-arrow-up"></i></a>
  48. </header>
  49.  
  50.  
  51. <script>
  52. $(function() {
  53. $('#player__heads').hide();
  54. $('.m_minecraftserverstatus_new').hide(); //Might require preset ID, if not working message me and I will fix it.
  55. $('.players').click(function(){
  56. $('#player__heads').fadeToggle('slow');
  57. });
  58. var onlinePlayerHeads = $(".player-grid a");
  59.  
  60. onlinePlayerHeads.each(function( i ) {
  61. var avtLink = $(this).children('img').attr('src');
  62. var names = $(this).data('minitooltip');
  63.  
  64. $("#player__heads").append('<a class="player__online" data-minitooltip='+ names +'><img src='+ avtLink +'></a>');
  65.  
  66.  
  67. });
  68. });
  69. $(function() {
  70. $('#enjin-tray-messaging,#enjin-tray').hide(0);
  71. $('header').prependTo('.body-wrap-2');
  72. var onlUsers = $('.featured').length;
  73. var news_auth = $('.m_news .info a').contents().filter(function() { return this.nodeType == 3; }).text();
  74. $('.m_news').find('.info a').text('Posted By ' + news_auth);
  75. $('.m_membersonline').find('.mask').text('Online Users - ' + onlUsers);
  76. $(window).load(function() {
  77. $('#loading__main').hide();
  78. $('#enjin-tray-messaging,#enjin-tray').show(0);
  79. var ip = new Clipboard('#ip');
  80.  
  81. ip.on("success", function() {
  82. $('.click__copy').html("IP has been copied!");
  83.  
  84. setTimeout(function() {
  85. $('.click__copy').html("Click to Copy!");
  86. }, 3000);
  87.  
  88. });
  89. $('.server__ip').hover(function() {
  90. $('.tooltip').stop().fadeIn();
  91. }, function() {
  92. $('.tooltip').stop().fadeOut();
  93. });
  94. $('.scroll__top').click(function() {
  95. $('html, body').animate({
  96. scrollTop: 0
  97. }, '400');
  98. });
  99. $('#ip, #ip1, .scroll__top, .players').css('cursor', 'pointer');
  100. $(window).on("scroll", function() {
  101. if ($(this).scrollTop() > 100) {
  102. $('.scroll__top').fadeIn(300);
  103. } else {
  104. $('.scroll__top').fadeOut(300);
  105. }
  106. });
  107. $(document).ready(function() {
  108.  
  109. getOnlinePlayers();
  110.  
  111. });
  112.  
  113. function getOnlinePlayers() {
  114.  
  115. $.getJSON("https://mcapi.us/server/status?ip=mc.dreamsurvival.nl", function(json) {
  116. if (json.players.now !== undefined) {
  117. $("#online,#online1").html(json.players.now);
  118. } else {
  119. $("#online,#online1").html("#");
  120. }
  121.  
  122. setTimeout(getOnlinePlayers, 5000);
  123. });
  124. }
  125.  
  126. });
  127. });
  128. </script>
  129.  
  130. </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement