var isIE=(document.all&&window.ActiveXObject&&!window.opera)?true:false;
document.write('<style type="text/css">');
document.write(".color_div_o {width:16px;height:16px;padding:4px 0 0 4px;background:#B6BDD2;cursor:crosshair;}");
document.write(".color_div_t {width:16px;height:16px;padding:4px 0 0 4px;background:#F1F2F3;}");
document.write(".color_div {border:#808080 1px solid;width:10px;height:10px;line-height:10px;font-size:1px;}");
document.write("</style>");
var color_id=1;
var color_bk=color_htm="";
color_htm+='<table cellpadding="0" cellspacing="0" bgcolor="#2875B9" width="160">';
color_htm+='<tr><td width="2" height="20"> </td>';
color_htm+='<td><input type="text" style="width:60px;height:12px;border:#A0A0A0 1px solid;" value="" id="color_viewview" onblur="color_select(this.value);" onkeyup="color_view(this.value);" ondblclick="this.value=\'\';"/></td>';
color_htm+="<td>&nbsp;&nbsp;&nbsp;</td>";
color_htm+='<td align="right" style="color:#FFFFFF;font-weight:bold;cursor:pointer;" onclick="color_close();" title="Close">&#215;&nbsp;</td>';
color_htm+="</tr>";
color_htm+="</table>";
color_htm+='<div id="eminer_color_show"></div>';
function Eh(d){var d=d?d:"select";
if(isIE){var e=navigator.appVersion.split("MSIE");
var a=parseFloat(e[1]);
if(a>=7||a<5){return;
}var c=document.body.getElementsByTagName(d);
for(var b=0;
b<c.length;
b++){c[b].style.visibility="hidden";
}}}function Es(d){var d=d?d:"select";
if(isIE){var e=navigator.appVersion.split("MSIE");
var a=parseFloat(e[1]);
if(a>=7||a<5){return;
}var c=document.body.getElementsByTagName(d);
for(var b=0;
b<c.length;
b++){c[b].style.visibility="visible";
}}}function color_show(id,color,obj){Eh();
if(document.getElementById("eminer_color")==null){var eminer_color_div=document.createElement("div");
with(eminer_color_div.style){zIndex=9999;
position="absolute";
display="none";
width="160px";
padding="1px";
top=0;
left=0;
border="#A0A0A0 1px solid";
backgroundColor="#FFFFFF";
}eminer_color_div.id="eminer_color";
document.body.appendChild(eminer_color_div);
}var aTag=obj;
var leftpos=toppos=0;
do{aTag=aTag.offsetParent;
leftpos+=aTag.offsetLeft;
toppos+=aTag.offsetTop;
}while(aTag.offsetParent!=null);
document.getElementById("eminer_color").style.left=(obj.offsetLeft+leftpos)+"px";
document.getElementById("eminer_color").style.top=(obj.offsetTop+toppos+20)+"px";
document.getElementById("eminer_color").innerHTML=color_htm;
color_id=id;
color_bk=color;
document.getElementById("eminer_color").style.display="";
if(color){color_view(color);
}color_setup(color);
}function color_hide(){document.getElementById("eminer_color").style.display="none";
Es();
}function color_close(){color_hide();
document.getElementById("color_img_"+color_id).style.backgroundColor="rgb("+color_bk+")";
}function color_select(a){document.getElementById("color_input_"+color_id).value=a.replace("rgb(","").replace(")","");
document.getElementById("color_img_"+color_id).style.backgroundColor=a;
color_hide();
}function color_setup(b){var a=["rgb(0,0,0)","rgb(153,51,0)","rgb(51,51,0)","rgb(0,51,0)","rgb(0,51,102)","rgb(0,0,128)","rgb(51,51,153)","rgb(51,51,51)","rgb(128,0,0)","rgb(255,102,0)","rgb(128,128,0)","rgb(0,128,0)","rgb(0,128,128)","rgb(0,0,255)","rgb(0,0,0)","rgb(128,128,128)","rgb(255,0,0)","rgb(255,153,0)","rgb(153,204,0)","rgb(51,153,102)","rgb(51,204,204)","rgb(51,102,255)","rgb(128,0,128)","rgb(153,153,153)","rgb(255,0,255)","rgb(255,204,0)","rgb(255,255,0)","rgb(0,255,0)","rgb(0,255,255)","rgb(0,204,255)","rgb(153,51,102)","rgb(192,192,192)","rgb(255,153,204)","rgb(255,204,153)","rgb(255,255,153)","rgb(204,255,204)","rgb(204,255,255)","rgb(153,204,255)","rgb(204,153,255)","rgb(255,255,255)"];
var c="";
c+='<table cellpadding="0" cellspacing="0">';
for(i=0;
i<a.length;
i++){if(i%8==0){c+="<tr>";
}c+='<td width="20" height="20">';
if(b==a[i]){c+='<div class="color_div_o" onmouseover="color_view(\''+a[i]+"');\" onclick=\"color_select('"+a[i]+"');\">";
}else{c+="<div class=\"color_div_t\" onmouseover=\"this.className='color_div_o';color_view('"+a[i]+"');\" onmouseout=\"this.className='color_div_t';\" onclick=\"color_select('"+a[i]+"');\">";
}c+='<div class="color_div" style="background:'+a[i]+'">&nbsp;</div></div></td>';
if(i%8==7){c+="</tr>";
}}c+="</table>";
document.getElementById("eminer_color_show").innerHTML=c;
}function color_view(a){try{document.getElementById("color_viewview").value=a;
document.getElementById("color_viewview").style.color=a;
document.getElementById("color_img_"+color_id).style.backgroundColor=a;
}catch(b){}}