<%
db="../data/fy2sc.mdb"'这里修改数据库路径或名称
Set conn = Server.CreateObject("ADODB.Connection")
dbpath="Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & Server.MapPath(db)
conn.Open dbpath
%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3c.org/TR/1999/REC-html401-19991224/loose.dtd">
<HTML xml:lang="gb2312" xmlns="http://www.w3.org/1999/xhtml">
<HEAD>
<TITLE></TITLE>
<META http-equiv=Content-Type content="text/html; charset=gb2312">
<LINK rev=stylesheet media=screen href="control/chinaindex_v0.9.css" type=text/css rel=stylesheet>
<SCRIPT language=javascript src="control/chinajs_v1.js" type=text/javascript></SCRIPT>

<META content="MSHTML 6.00.2900.3199" name=GENERATOR></HEAD>
<BODY onload=initAd();sr_initialize()>
<SCRIPT language=javascript type=text/javascript>
    try{
    	slideLine('slidetexts', 5500, 32, 20);
    }catch(e) {}
  </SCRIPT>
<DIV id=content_right_top>
<UL class=content_right_top_1>
  <LI>
    <!--Adforward Begin:-->
    <!--Adforward End-->
  </LI>
</UL><!--slidebox start-->
<DIV id=slideBox>
<DIV id=slide>

<UL>
  <LI class=l_h><A class=btn_zchy href="../user_main.asp" target="_top">会员信息</A></LI>
  <LI class=r><A class=btn_cxt href="../user_csAdd.asp" target="_top">发布信息</A></LI>
</UL>

<DIV class=cont_l id=sc_1>
<DIV><A class=arrow href="../user_main.asp" target="_top"><%=session("userName")%>&nbsp;欢迎您的登录</A></DIV>
<DIV><A class=arrow href="#" onClick="return false">总资产：<%=getzichanxinyu("总资产")%>&nbsp;信誉值：<%=getzichanxinyu("信誉值")%></A></DIV>
</DIV>

<DIV class=hide id=sc_2>
<DIV><A class=arrow href="../user_mypro.asp"  target="_top">出售信息：<%=getchuqiu("出售")%>条</A></DIV>
<DIV><A class=arrow href="../user_mybuy.asp"  target="_top">求购信息：<%=getchuqiu("求购")%>条</A></DIV>
</DIV>
<UL>
  <LI class=l><A class=btn_tggs href="#">寻找买家</A></LI>
  <LI class=r><A class=btn_fbxx href="#">申请推荐</A></LI>
</UL>
<DIV class=hide id=sc_3>
<DIV><A class=arrow href="#">按车辆型号查找</A></DIV>
<DIV><A class=arrow href="#">按价格区间查找</A></DIV>
</DIV>
<DIV class=hide id=sc_4>
<DIV><A class=arrow href="#">申请推荐二手车，多百倍出售机会&nbsp;&nbsp;进入>></A></DIV>
</DIV>
<UL>
  <LI class=l><A class=btn_xzmj href="../user_main.asp" target="_top">会员中心</A> 
  </LI>
  <LI class=r><A class=btn_alisoft href="../user_loginout.asp">会员退出</A> 
</LI></UL>
<DIV class=hide id=sc_5>
<DIV><A class=arrow href="../user_modiziliao.asp" target="_top">修改信息</A></DIV>
<DIV><A class=arrow href="../user_main.asp" target="_top">申请服务</A></DIV>
</DIV>
<DIV class=hide id=sc_6>
<DIV><A class=arrow href="#">欢迎再次登录，莆田二手车网欢迎您。</A></DIV>
</DIV></DIV></DIV>
<SCRIPT language=javascript src="control/alicn_tab2.js" type=text/javascript></SCRIPT>
</DIV>
<DIV class=lh15 id=offerTimeInfo style="DISPLAY: none">9：00 - 18：00 每5分钟更新，<SPAN 
id=lastTime></SPAN> </DIV>
<SCRIPT type=text/javascript>clickTime();</SCRIPT>
<DIV id=right_1></DIV>
<DIV class=clr></DIV>
<DIV class=clr></DIV>
<DIV id=right_3></DIV>
<SCRIPT language=javascript type=text/javascript>LetterCategory.init("categoryCtrl","categoryList","right_1_content");</SCRIPT>
</BODY>
</HTML>
<%
'==============================================================================================
'功能：获得出售或求购信息个数
function getchuqiu(type1)
	dim tmp
	if type1="出售" then
		set rschuqiu = server.CreateObject("adodb.recordset")
		rschuqiu.open "select * from product where userId="& session("userId23") &" and fa_chuqiu = '出售'",conn,1,1
		if not rschuqiu.eof then
			tmp = rschuqiu.recordcount
		else
			tmp = 0
		end if
		rschuqiu.close
		set rschuqiu =nothing
		getchuqiu = tmp
		exit function
	elseif type1="求购" then
		set rschuqiu = server.CreateObject("adodb.recordset")
		rschuqiu.open "select * from product where userId="& session("userId23") &" and fa_chuqiu = '求购'",conn,1,1
		if not rschuqiu.eof then
			tmp = rschuqiu.recordcount
		else
			tmp = 0
		end if
		rschuqiu.close
		set rschuqiu =nothing
		getchuqiu = tmp
		exit function
	else
		getchuqiu = 0
		exit function
	end if
end function

'==============================================================================================
'功能：获得总资产和信誉值
function getzichanxinyu(type1)
if session("userId23") <> "" then
	set rs_3 = server.CreateObject("ADODB.Recordset")
	rs_3.open "select * from userJiFen where userId = "& session("userId23") &" ",conn,1,1
	
	if not rs_3.eof then
		if type1 = "总资产" then
			getzichanxinyu = rs_3("yikabeibei")
		elseif type1 = "信誉值" then
			getzichanxinyu = rs_3("yikaxinyu")
		else
			getzichanxinyu = 0
		end if
	else
		getzichanxinyu = 0
	end if
	
	rs_3.close
	set rs_3 = nothing
else
	getzichanxinyu = 0
end if
end function
%>