---
title: "javascript 进度条"
author: "microapple"
date: "2011-04-11T11:09:00Z"
tags: []
categories: ["编程语言"]
slug: "javascript"
draft: false
lastmod: "2013-03-02T11:02:30Z"
id: 997116
url: "https://microapple.iteye.com/blog/997116"
---

1.js

```js

function daoJiShi() {
		document.getElementById('thebar').innerHTML = '<div class="progressbar_3" id="thebar1">'+'<div class="text">'+hhhh+'%</div>'
				+'<div class="bar" style="width:'+hhhh+'%;"></div>'+'</div>'+'<br/><div>&nbsp;&nbsp;制品正在上传...</div>';
		hhhh = hhhh + 1;
		if(hhhh>100){
			window.location.href='${path}/check/analyMusic.jsp';
		}
		setTimeout('daoJiShi()', 100);
		
	}

```

2.html

```html
<div class=".wrap" align="center" id="thebar">

								<DIV class=putin_con>
									<P align="center">
										上传制品：
										<input type="file" name="image" id="file1" size="50"
											style="HEIGHT: 20px">
									</P>
									<br>
									<br>
									<P align="center">
										<INPUT id=Button class=input2 name=Button value=提交
											type="button" onclick=LimitAttach();>
										<INPUT id=Button class=input2 name=Button value=取消
											type="reset">
									</P>

									<DIV style="DISPLAY: none; COLOR: red" id=VS></DIV>

								</DIV>
							</div>

```