惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

H
Hackread – Cybersecurity News, Data Breaches, AI and More
C
Check Point Blog
Hacker News: Ask HN
Hacker News: Ask HN
cs.CL updates on arXiv.org
cs.CL updates on arXiv.org
WordPress大学
WordPress大学
P
Proofpoint News Feed
V
Visual Studio Blog
C
Cyber Attacks, Cyber Crime and Cyber Security
N
Netflix TechBlog - Medium
C
CXSECURITY Database RSS Feed - CXSecurity.com
博客园 - 聂微东
Threat Intelligence Blog | Flashpoint
Threat Intelligence Blog | Flashpoint
博客园 - 叶小钗
Cisco Talos Blog
Cisco Talos Blog
S
Schneier on Security
T
Threat Research - Cisco Blogs
腾讯CDC
cs.AI updates on arXiv.org
cs.AI updates on arXiv.org
The Hacker News
The Hacker News
Google DeepMind News
Google DeepMind News
Microsoft Security Blog
Microsoft Security Blog
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
GbyAI
GbyAI
N
News | PayPal Newsroom
L
LINUX DO - 最新话题
酷 壳 – CoolShell
酷 壳 – CoolShell
P
Palo Alto Networks Blog
T
Tenable Blog
S
Secure Thoughts
T
Threatpost
V2EX - 技术
V2EX - 技术
大猫的无限游戏
大猫的无限游戏
Martin Fowler
Martin Fowler
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
Vercel News
Vercel News
罗磊的独立博客
P
Privacy & Cybersecurity Law Blog
Engineering at Meta
Engineering at Meta
小众软件
小众软件
Google DeepMind News
Google DeepMind News
N
News and Events Feed by Topic
Y
Y Combinator Blog
CTFtime.org: upcoming CTF events
CTFtime.org: upcoming CTF events
C
Cybersecurity and Infrastructure Security Agency CISA
P
Proofpoint News Feed
L
Lohrmann on Cybersecurity
P
Privacy International News Feed
H
Heimdal Security Blog
量子位
B
Blog

博客园 - 痞子再

介绍50个 WordPress 动作挂钩 决定如何开发你的WordPress主题框架 WordPress 主题框架是如何工作的 WordPress主题制作教程[壹] - 了解WP&结构&索引 jQuery UI Datepicker -- jQuery日历控件中的精品(UI绚丽) godaddy.com免费10G空间申请步骤详解 godaddy免费空间完美安装部署dedecms UrlRewriter使用详解 - 痞子再 - 博客园 google的CDN内容分发网络来加载jQuery库 - 痞子再 - 博客园 压缩和解压缩的方法 from Byte[] 利用google API实现全文翻译的Web Service 字符串操作类 NET代码积累之一 让visual studio 2005 自动为类加版权 C#日期格式化 UrlRewriter 使用详解 (Friendly Url) web.config中配置字符串中特殊字符的处理 - 痞子再 - 博客园 漂浮层广告代码[层为隐藏,点击广告后层消失][24小时/次] 网页采集时,常用的几种正则表达式 C# Check is No number - 痞子再
JavaScript模拟进度条
痞子再 · 2008-05-22 · via 博客园 - 痞子再

<html>

<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>进度条</title>
</head>

<body>

 
××××××××××注释以内的代码可以复制××开始××××××××××××
<div id="progress"></div>
<div id="DivFlash" style="display: none;">这里放上FLASH</div>

<script type="text/javascript" language="javascript">
<!--
function CProgress(progressIdStr, min, max, pos)
{
    this.progressIdStr = progressIdStr;
    this.progressId = document.getElementById(this.progressIdStr);
    this.barIdStr = progressIdStr + "_bar";
    this.barId = null;
   
    this.min = (min>=0)?min:0;
    this.max = (max>=min)?max:min;
    this.pos = (pos>=min && pos<=max)?pos:min;
    this.step = 1;
   
    this.progressWidth = 100;
    this.progressHeight = 15;
   
    this.Create = Create;

    this.SetStep = SetStep;
    this.SetPos = SetPos;
    this.Inc = Inc;
    this.Desc = Desc;
}

function Create()
{
    if (document.all)
    {
        this.progressId.style.width = this.progressWidth+2;
    }
    else
    {
        this.progressId.style.width = this.progressWidth;
    }
    var pBgColor = '#0066FF';  //滚动条的颜色
    this.progressId.style.height = this.progressHeight;
    this.progressId.style.fontSize = this.progressHeight;
    this.progressId.style.border = "1px solid #000000";  //空白地方的颜色
    this.progressId.innerHTML = "<div id=\"" + this.barIdStr + "\" style=\"background-color:"+pBgColor+";height:100%;\"></div>";
    this.barId = document.getElementById(this.barIdStr);
    this.SetPos(this.pos);
}

function SetStep(step)
{
    this.step = step;
}

function SetPos(pos)
{
    pos = (pos<=this.max)?pos:this.max;
    pos = (pos>=this.min)?pos:this.min;
    this.barId.style.width = (this.progressWidth*pos)/this.max;
}

function Inc()
{
    this.pos += this.step;
    this.SetPos(this.pos);
   if(this.pos >= progress.progressWidth)
   {
        document.getElementById('progress').style.display = 'none';
 document.getElementById('DivFlash').style.display = '';
       
   }
}

function Desc()
{
    this.pos -= this.step;
    this.SetPos(this.pos);
}

var DivWidth = 600;//滚动条的宽度
var DivTime  = 10; //滚动间隔时间 毫秒
var Divaaa =    50;//滚动的长度
var progress = new CProgress("progress", 0, DivWidth, Divaaa);
progress.progressWidth = DivWidth;
progress.Create();
setInterval("progress.Inc();", DivTime);
//-->
</script>

××××××××××注释以内的代码可以复制××结束××××××××××××

</body>

</html>