js
鹿鸣_呦呦
这个作者很懒,什么都没留下…
展开
-
js数组随即取值
<!DOCTYPE html><html lang="en"><head> <meta charset="UTF-8"></head><body></body><script> window.onload = function() { var arr = ["009", "0...原创 2020-01-09 09:59:58 · 254 阅读 · 0 评论 -
js 格式化时间戳函数
function formatDate(date,fmt){ if(/(y+)/.test(fmt)){ date= new Date(date*1000); fmt = fmt.replace(RegExp.$1,(date.getFullYear()+&amp;quot;&amp;quot;).substr(4-RegExp.$1.length)); var o ={ ...原创 2018-11-21 14:37:48 · 1566 阅读 · 1 评论 -
doT.js判断条件
define(function() { return[ '{{for(var item in it) { }}', '<li>', '{{if (parseInt(item) === 0){ }}', '<span class="num module_common_num_first">1</span>', '{{ }els...原创 2019-02-22 10:41:39 · 3104 阅读 · 0 评论 -
微博墙
<div class="xlc-wb"> <h4 class="title">聊新浪潮论坛</h4> <link rel="stylesheet" href="http://news.sina.com.cn/css/268/2011/1110/17/weibo-all.css" / id="c...原创 2019-04-22 14:04:42 · 173 阅读 · 0 评论 -
简单的回到顶部
$(function(){ function floatBar(){ var _fbr_h = $(window).height(); if($(window).scrollTop() >= _fbr_h){ $("#ScrollToTop").css('displ...原创 2019-04-18 11:22:58 · 109 阅读 · 0 评论 -
百度分享的使用办法
<script type="text/javascript" id="bdshare_js" data="type=tools&uid=bc3b1c41-57af-4bd5-89cd-76dd6e6ee75f&" ></script><script type="text/javascript" id="bdshell_js"&g...原创 2019-04-18 18:00:31 · 222 阅读 · 0 评论 -
scrollToBottom
/** scrollToBottom({ container: window, target: '#j_demo', triggerDistance: 0, callBack: function(){ // 滚动到底部了 }, time: 300 }); */...原创 2019-06-24 16:57:26 · 2663 阅读 · 0 评论