<!--#include file="../../p_inc/Include_func.asp"-->
<!--#include file="../inc/classDbPager.asp"-->
<!--#include file="../inc/public.asp"-->
<!--#include file="../inc/openconn.asp"-->

<html>
<head>
<title>html生成所有地区名站导航</title>
<style type="text/css">
<!--
body {
	margin-left: 0px;
	margin-top: 0px;
	margin-right: 0px;
	margin-bottom: 0px;
	background-color: #E4EDF9;
}
body,td,th {
	font-size: 12px;
}
-->
</style>

</head>

<body>
<script>
function scrollWindow(){this.scroll(0, 6500000);sett=setTimeout('scrollWindow()',1);}
scrollWindow();
function scrollWindow2(){clearTimeout(sett)}
document.ondblclick=scrollWindow2;
</script>
<%
Response.Buffer=True
response.contenttype="text/html;charset=gb2312"
Server.ScriptTimeOut=9999999

Pstr=""
Pstr2=""
str=ReadAllTextFile("../qingtiandy_tool/citys.js")
str_a=body2s(str,"[""","]","#####",true)
str_a_1=split(str_a,"#####")
For i=0 To Ubound(str_a_1)-1
	ka=Replace(str_a_1(i),"""","")
	ka_1=split(ka,",")
	mlength=Ubound(ka_1)
	m1=ka_1(1) '父id
	m2=ka_1(0) '名字
	m3=ka_1(2) 'id
	IF mlength=3 And m1<>"0" Then
		Pstr=Pstr&m3&","
		Pstr2=Pstr2&m2&","
	End IF
Next
Pstr_a=split(Pstr,",")
Pstr2_a=split(Pstr2,",")

id=Replace(Request("id"),"'","")


For pi=0 To Ubound(Pstr_a)-1
	s1=Pstr2_a(pi)
	s2=Pstr_a(pi)
	Response.Write "正在生成地区("&pi+1&"/"&Ubound(Pstr_a)&")(<font color=red>"&s1&"</font>)  "
	Response.Flush()	
	Set oRs=Server.CreateObject(G_RS)
	oRs.open "Select * From qingtiandy_tool Where m_type1=10 And m_city="&s2&" Order By m_no Desc,Id Desc",conn,1,1
	pstr="var qtcms_m_province_const=['"&s2&"','"&s1&"']"&vbcrlf
	pstr=pstr&"var qtcms_m_province_arr=["
	Do While Not oRs.Eof
		om_name=oRs("m_name")
		om_color=oRs("m_color")
		om_url=GetUrl_httpAll(oRs("m_url"))
		p_tempstr="['"&om_name&"','"&om_url&"','"&om_color&"'],"
		pstr=pstr&p_tempstr
		oRs.MoveNext
	Loop
	pstr=pstr&"['','','']]"
	IF s2="1" Then
		ohurl=url_(Array("province","0",""))
		N_Fso.WriteToFile ohurl,pstr	
	End IF
	ohurl=url_(Array("province",s2,""))
	N_Fso.WriteToFile ohurl,pstr
	Response.Write "完成<br>"
Next
response.write "<font color=red><b>生成所有地区名站导航完成！</b></font><p>"
%>
</body>

</html>