页面默认值显示 function focusInputEle(o) { if (o.value == getAttributeValue(o, 'defaultVal')) { o.value = ''; o.style.color = "#000000"; } } function blurInputEle(o) { if (o.value == '') { o.value = getAttributeValue(o, 'defaultVal'); o.style.color = "#999999"; } } function getAttributeValue(o, key) { if (!o.attributes) return null; var attr = o.attributes; for ( var i = 0; i < attr.length; i++) { if (key.toLowerCase() == attr[i].name.toLowerCase()) return attr[i].value; } return null; } 证件编号: 如果文章对你有所帮助,希望施舍点包子钱,在下支付宝账号: 非常感谢 13718045310