Mayx's Home Page https://mabbs.github.io
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

56 lines
1.9 KiB

  1. (function() {
  2. var $backToTopTxt = "返回顶部", $backToTopEle = $('<div class="backToTop"></div>').appendTo($("body"))
  3. .text($backToTopTxt).attr("title", $backToTopTxt).click(function() {
  4. $("html, body").animate({ scrollTop: 0 }, 120);
  5. }), $backToTopFun = function() {
  6. var st = $(document).scrollTop(), winh = $(window).height();
  7. (st > 0)? $backToTopEle.show(): $backToTopEle.hide();
  8. };
  9. $(window).bind("scroll", $backToTopFun);
  10. $(function() { $backToTopFun(); });
  11. })();
  12. $(function(){
  13. $("div#landlord").mouseenter(function(){
  14. $("div.live_ico_box").fadeIn();
  15. });
  16. $("div#landlord").mouseleave(function(){
  17. $("div.live_ico_box").fadeOut();
  18. });
  19. function showHitS(hits){
  20. $.get("https://summary.mayx.eu.org/count_click?id="+hits.id,function(data){
  21. hits.innerHTML=Number(data);
  22. });
  23. }
  24. function showHitCount() {
  25. var visitors=$(".visitors-index");
  26. for(var i = 0; i < visitors.length; i++){
  27. showHitS(visitors[i]);
  28. }
  29. }
  30. function addCount() {
  31. var visitors=$(".visitors");
  32. $.get("https://summary.mayx.eu.org/count_click_add?id="+visitors[0].id,function(data){
  33. visitors[0].innerHTML=Number(data);
  34. });
  35. }
  36. if ($('.visitors').length == 1) {
  37. addCount();
  38. } else if ($('.visitors-index').length > 0){
  39. showHitCount();
  40. }
  41. });
  42. today = new Date();
  43. timeold = (today.getTime() - lastUpdated.getTime());
  44. secondsold = Math.floor(timeold / 1000);
  45. e_daysold = timeold / (24 * 60 * 60 * 1000);
  46. daysold = Math.floor(e_daysold);
  47. if (daysold > 90) {
  48. $("html")[0].style = "-webkit-filter: grayscale(100%);filter:progid:DXImageTransform.Microsoft.BasicImage(graysale=1);";
  49. $("html")[0].innerHTML = $("html")[0].innerHTML.replace(/Mayx/g, "Ghost");
  50. console.warn("Mayx may already be Dead");
  51. }
  52. var message_Path = '/Live2dHistoire/live2d/';
  53. var talkAPI = "https://turing-api.mayx.eu.org/";

Powered by TurnKey Linux.