//按时间查询
function historyFind(form)
{
	var j,i;
	var ch;
	var temp;
	var ye;
	var mo;
	var da;
	var fileFStr, fileLStr;
	var flname, fstr, lstr;
	temp=form.txt_date.value
	i=temp.indexOf("-",0);
	if( i==-1){
		i=0;
		i=temp.indexOf("/",0);	
		if( i==-1) {
			i=0;
			i=temp.indexOf(".",0);	
			if(i==-1)  return false;
			else ch=".";
		}
		else ch="/";
	}
	else ch="-"
	i=temp.indexOf(ch,0);
	ye=temp.substr(0,i);
	j=temp.indexOf(ch,i+1);
	mo=temp.substr(i+1,j-i-1);
	if((j-i-1)==1) mo="0"+mo;
	i=temp.length
	da=temp.substr(j+1,i-j)
	if((i-j)==2) da="0"+da;

	flname =form.txt_position.value;
	i = flname.lastIndexOf('/');
	fstr = flname.substring(0,i);
	lstr = flname.substring(i+1);
	if( lstr.length > 0 ) {
		j = lstr.lastIndexOf('.');
		fileFStr = lstr.substring(0,i);
		fileLStr = lstr.substring(i+1);
	} else {
		fileFStr = 'index';
		fileLStr = 'html';
	}
	fileFStr = 'index';
	fileLStr = 'html';
	flname = fstr + '/' + fileFStr +  ye + mo + da +'.' + fileLStr;
	document.write("");
	this.location = flname;
}


//按月查询
function monthFind(form)
{
	var my;
	var mm;
	var fileFStr, fileLStr;
	var flname, fstr, lstr;
	my=form.selyear.value
	mm=form.selmonth.value
	flname =form.txt_position.value;
	i = flname.lastIndexOf('/');
	fstr = flname.substring(0,i);
	lstr = flname.substring(i+1);
	if( lstr.length > 0 ) {
		j = lstr.lastIndexOf('.');
		fileFStr = lstr.substring(0,i);
		fileLStr = lstr.substring(i+1);
	} else {
		fileFStr = 'index';
		fileLStr = 'html';
	}
	fileFStr = 'index';
	fileLStr = 'html';
	flname = fstr + '/' + fileFStr +  my + mm +'.' + fileLStr;
	document.write("");
	this.location = flname;
}

function gsdaform_search(){    
	var dm=document.gsda_form.jbqk.value;  
        document.gsda_form.companyid.value=dm;
return true;
}

function gsda_search(form){    
	var dm=form.gpdm.value;  
        window.open("http://quote.p5w.net/quote/fszs.asp?gpdm="+dm,'newgszx');
	
	}

function search_tipkey()
{
	window.status='多关键词间用"*","+","-"，表示"同时满足","满足其一","不包含"-"后的关键词';
}

function KeySearch_onsubmit()
{
	var radvalue;
	var tempValue;
	if(document.SearchForm.SearchWord.value=="")
	{
		alert("检索表达式不能为空!");
		return false;
	}
	radvalue=document.SearchForm.radTitle[1].checked;
	if( radvalue == true ) {
		tempValue = document.SearchForm.SearchWord.value;
		document.SearchForm.SearchWord.value='信息标题=%' + tempValue + '%';
	}
	return true;
}


function sField(newfield)
{
document.write("");
this.location="/p5w/home/today/industry/"+newfield+"/index.html";
}

function gsdahk_search(form){    
	var dm=form.jbqk.value;  
        document.write("");  
	this.location="http://market.p5w.net/p5w/hk/list/gsgk.asp?dmdm="+dm;
}

