<!--
function NoError(){return true;}
window.onerror = NoError;
//-->
function searchstockcode()
{
	stockcode_current=document.getElementById("StockCode").value;
	if (stockcode_current=="输代码、名称或拼音缩写" || stockcode_current=="") stockcode_current="600280";
	var re=/[0-9]{6}/; 
	var re2=/[0-9]{1,}/; 
	var re3=/[^0-9]{1,}/; 
	bool1=stockcode_current.match(re)
	bool2=stockcode_current.match(re2)
	bool3=stockcode_current.match(re3)
	if(bool1!=null && stockcode_current.length==6){
	window.open('http://quote.eastmoney.com/'+stockcode_current+'.html');}
	else {
	if (bool2!=null && bool3==null && stockcode_current.length<3){alert("股票代码至少输入3位！");return false;}
	if (bool2==null && bool3!=null && stockcode_current.length<2){alert("模糊查询时关键字至少2位！");return false;}
	window.open('http://quote.eastmoney.com/quote.asp?stockcode='+escape(stockcode_current));}
	return(false);
}
function searchstockcodei()
{
stockcode_current=document.getElementById("StockCodei").value;
if (stockcode_current=="输代码、名称或拼音缩写" || stockcode_current=="") stockcode_current="600280";
var re=/[0-9]{6}/; 
var re2=/[0-9]{1,}/; 
var re3=/[^0-9]{1,}/; 
bool1=stockcode_current.match(re)
bool2=stockcode_current.match(re2)
bool3=stockcode_current.match(re3)
if(bool1!=null && stockcode_current.length==6){
window.open('http://quote.eastmoney.com/'+stockcode_current+'.html');}
else {
if (bool2!=null && bool3==null && stockcode_current.length<3){alert("股票代码至少输入3位！");return false;}
if (bool2==null && bool3!=null && stockcode_current.length<2){alert("模糊查询时关键字至少2位！");return false;}
window.open('http://quote.eastmoney.com/quote.asp?stockcode='+escape(stockcode_current));}
return(false);
}
function rewrite()
{
stockcode_current=document.getElementById("StockCode").value;
if (stockcode_current=="输代码、名称或拼音缩写" || stockcode_current=="") stockcode_current="600280";
var re=/[0-9]{6}/; 
var re2=/[0-9]{1,}/; 
var re3=/[^0-9]{1,}/; 
bool1=stockcode_current.match(re)
bool2=stockcode_current.match(re2)
bool3=stockcode_current.match(re3)
if(bool1!=null && stockcode_current.length==6){
window.open('http://quote.eastmoney.com/'+stockcode_current+'.html');return(false);}
else {
if (bool2!=null && bool3==null && stockcode_current.length<3){alert("股票代码至少输入3位！");return false;}
if (bool2==null && bool3!=null && stockcode_current.length<2){alert("模糊查询时关键字至少2位！");return false;}
window.open('http://quote.eastmoney.com/quote.asp?stockcode='+escape(stockcode_current));}
return(false);
}
function searchgsstockcode()
{
	stockcode_current=document.getElementById("StockCode").value;
	var re=/[0-9]{6}/; 
  bool1=stockcode_current.match(re)
  if(bool1!=null)
  {
		window.open('http://q.eastmoney.com/q.aspx?StockCode='+escape(stockcode_current));
	}
	else
	{
		window.open('http://q.eastmoney.com/');
	}
}
function searchgsstockcodei()
{
	stockcode_current=document.getElementById("StockCodei").value;
	var re=/[0-9]{6}/; 
  bool1=stockcode_current.match(re)
  if(bool1!=null)
  {
		window.open('http://q.eastmoney.com/q.aspx?StockCode='+escape(stockcode_current));
	}
	else
	{
		window.open('http://q.eastmoney.com/');
	}
}
function aa()
{
	stockcode_current=document.getElementById("StockCode").value;
	var re=/[0-9]{6}/; 
  bool1=stockcode_current.match(re)
  if(bool1!=null)
  {
		window.open('http://q.eastmoney.com/q.aspx?StockCode='+escape(stockcode_current));
	}
	else
	{
		window.open('http://q.eastmoney.com/');
	}
}
function researchstockcode()
{
stockcode_current=document.getElementById("ReStockCode").value;
if (stockcode_current=="输代码、名称或拼音缩写" || stockcode_current=="") stockcode_current="600280";
var re=/[0-9]{6}/; 
var re2=/[0-9]{1,}/; 
var re3=/[^0-9]{1,}/; 
bool1=stockcode_current.match(re)
bool2=stockcode_current.match(re2)
bool3=stockcode_current.match(re3)
if(bool1!=null && stockcode_current.length==6){
window.open('http://quote.eastmoney.com/'+stockcode_current+'.html');}
else {
if (bool2!=null && bool3==null && stockcode_current.length<3){alert("股票代码至少输入3位！");return false;}
if (bool2==null && bool3!=null && stockcode_current.length<2){alert("模糊查询时关键字至少2位！");return false;}
window.open('http://quote.eastmoney.com/quote.asp?stockcode='+escape(stockcode_current));}
return(false);
}
function quotetoguba()
{       
  stockcode_current=document.getElementById("StockCode").value;
  var re=/[0-9]{6}/; 
  bool1=stockcode_current.match(re)
  if(bool1!=null)
  {window.open('http://guba.eastmoney.com/'+stockcode_current+',guba.html');}
  else
  {window.open('http://guba.eastmoney.com/');}
}
function quotetogubai()
{       
  stockcode_current=document.getElementById("StockCodei").value;
  var re=/[0-9]{6}/; 
  bool1=stockcode_current.match(re)
  if(bool1!=null)
  {window.open('http://guba.eastmoney.com/'+stockcode_current+',guba.html');}
  else
  {window.open('http://guba.eastmoney.com/');}
}
function gguubbaareload(gburl)
{
document.getElementById("gguubbaa").src=gburl;
}
function gotohq2(stockcode)
{
window.open('http://hq2.eastmoney.com/favor_post.aspx?hq_stock='+stockcode);
}
function color(x)
{
	if(x=="1"){return '#FF0000'}
	else if(x=="-1"){return '#009900'}
	else{return '000000'}
}
function zhangdie(flag)
{
	if(flag==1||flag==-1){return 'id=\"hongdise\"';}
}
function myrefresh()
{
	window.location.reload();
}
function Getggheight()        
{
  var arr = document.cookie.match(new RegExp("(^| )"+escape("ggheight")+"=([^;]*)(;|$)"));
  if(arr != null) return unescape(arr[2]); return null;
}
function Setggheight(value)
{
    var exp  = new Date();
    exp.setTime(exp.getTime() + 5*60*1000);
    document.cookie = "ggheight="+ escape (value) + ";expires=" + exp.toGMTString()+";path=/;domain=.eastmoney.com";
}
function ggformcheck(){
if(checkspace(document.theform.topic.value) || checkspace(document.theform.edit.value))
{
	if(checkspace(document.theform.topic.value))
	{alert("请输入留言标题。");document.theform.topic.focus();}
	else
	{alert("请输入留言内容。");document.theform.edit.focus();}
}
else
{
document.theform.submit();
alert("留言发表完成！如果没有看到内容，请刷新本页面。");
myrefresh();
}
}
function checkspace(checkstr)
{
  var str = '';
  for(i = 0; i < checkstr.length; i++) 
  {str = str + ' ';}
  return (str == checkstr);
}
function getggformCookie(name) 
{  
  var cookieValue="";   
  var search = name + "=";   
  if(document.cookie.length>0)     
  {     
    offset= document.cookie.indexOf(search); 
    if(offset   !=   -1)
    {
   	  offset   +=   search.length;   
      end   =   document.cookie.indexOf(";",   offset);   
      if   (end   ==   -1)   end   =   document.cookie.length;
      cookieValue   =   unescape(document.cookie.substring(offset,end))
    }   
  }   
  return   cookieValue; 
}
function color1(x,y)
{
	if(x-y>0){return 'style=\"color: #FF0000;font-size:12px\"'}
	else if(x-y<0){return 'style=\"color: #009900;font-size:12px\"'}
	else{return ''}
}
function zs_zhangdie(zf)
{
	if(zf>0){return '↑'}
	else if(zf<0){return '↓'}
	else{return ''}
}
function dapan_display()
{
	document.getElementById("zstop_000001").src="http://hqdigi.eastmoney.com/C/zs_data.aspx";
	zs_arr=new Array()
	zs_arr.push(zs_str_000001.split(","))
	zs_arr.push(zs_str_399001.split(","))
	zs_arr.push(zs_str_000002.split(","))
	zs_arr.push(zs_str_399002.split(","))
	zs_str="<a href=http://quote.eastmoney.com/quote1_1.html target=_blank>上证</a>：<font "+color1(zs_arr[0][3],0)+"><span class=zsArialb>"+zs_arr[0][2]+"</span></font>(<a href='http://quote.eastmoney.com/external_rank_list1.html' target='_blank'><font color=red>涨:"+zs_arr[2][12]+"</font></a>&nbsp;平:"+zs_arr[2][14]+"&nbsp;<a href='http://quote.eastmoney.com/external_rank_list2.html' target='_blank'><font color=#009900>跌:"+zs_arr[2][13]+"</font></a>)&nbsp;<font "+color1(zs_arr[0][3],0)+">"+zs_zhangdie(zs_arr[0][3])+"<span class=zsArialb>"+zs_arr[0][3]+"</span>&nbsp;&nbsp;"+zs_zhangdie(zs_arr[0][3])+"<span class=zsArialb>"+zs_arr[0][4]+"</span></font>&nbsp;&nbsp;<font "+color1(zs_arr[0][3],0)+"><span class=zsArialb>"+(zs_arr[0][6]/10000).toFixed(2)+"</span></font>亿元";
	zs_str=zs_str+"&nbsp;&nbsp;&nbsp;&nbsp;<a href=http://quote.eastmoney.com/quote1_5.html target=_blank>深证</a>：<font "+color1(zs_arr[1][3],0)+"><span class=zsArialb>"+zs_arr[1][2]+"</span></font>(<a href='http://quote.eastmoney.com/external_rank_list15.html' target='_blank'><font color=red>涨:"+zs_arr[3][12]+"</font></a>&nbsp;平:"+zs_arr[3][14]+"&nbsp;<a href='http://quote.eastmoney.com/external_rank_list16.html' target='_blank'><font color=#009900>跌:"+zs_arr[3][13]+"</font></a>)&nbsp;<font "+color1(zs_arr[1][3],0)+">"+zs_zhangdie(zs_arr[1][3])+"<span class=zsArialb>"+zs_arr[1][3]+"</span>&nbsp;&nbsp;"+zs_zhangdie(zs_arr[1][3])+"<span class=zsArialb>"+zs_arr[1][4]+"</span></font>&nbsp;&nbsp;<font "+color1(zs_arr[1][3],0)+"><span class=zsArialb>"+(zs_arr[1][6]/10000).toFixed(2)+"</span></font>亿元";
	document.getElementById("dapanzhishuggtop").innerHTML=zs_str;
}
function helpdiv_close(id){var o = document.getElementById(id);starchina();var j=100;var sobjTimer;var sobjTimer2;function change(){j=j-10;o.style.filter = "Alpha(Opacity=" + j + ")";o.style.opacity = j/100;if(j<0) {window.clearInterval(sobjTimer);}}function starchina(){sobjTimer =window.setInterval(change,10);}}