<html>
<meta http-equiv="content-type" content="text/html; charset=UTF-8" />
<head>
<title></title>
<script type="text/javascript">
function Reader(content, cID, stopID, continueID) {
this.conLoad = document.getElementById(cID);
this.stopBtn = document.getElementById(stopID);
this.continueBtn = document.getElementById(continueID);
this.content = content;
this.index = 0;
var t = this;
this.stopBtn.onclick = (
function () {
return function () {
t.stopReader(t);
};
})(t);
this.continueBtn.onclick = (
function () {
return function () {
t.continueReader(t);
};
})(t);
}
Reader.prototype = {
startReader : function () {
var t = this;
t.toId = setInterval(function () {
if (t.content[t.index]) {
t.conLoad.innerHTML += t.content[t.index];
}
t.index++;
if (t.content.length == t.index) {
clearInterval(t.toId);
t.conLoad.innerHTML += "【未完待續(xù)】";
}
}, 200);
},
stopReader : function (t) {
t.flag = true;
clearInterval(t.toId);
},
continueReader : function (t) {
if (t.flag)
t.startReader();
t.flag = false;
}
};
var content = "蒙古親王僧格林沁
主站蜘蛛池模板:
土默特右旗|
井研县|
抚宁县|
高要市|
四川省|
泸水县|
色达县|
左云县|
洪江市|
增城市|
科尔|
山阴县|
司法|
徐水县|
饶河县|
靖远县|
东方市|
霞浦县|
安阳市|
桦南县|
盐池县|
乾安县|
天门市|
青河县|
梨树县|
会理县|
桃源县|
九江市|
高邑县|
乐亭县|
九寨沟县|
鄢陵县|
辽中县|
佛教|
金沙县|
靖远县|
宁强县|
麦盖提县|
克拉玛依市|
通河县|
桦南县|