<!--#include file="../inc/conn.asp"-->
<%
id=trim(request("id"))
uid=trim(request("uid"))
tab=trim(request("tab"))

select case tab
  case "cw_hr"
	 html=lx_hr()
  case "cw_job","cw_info","cw_hous"
	 html=lx_info()
end select

Function lx_hr()
  If session("user")<>"" then
       set rs=server.CreateObject("adodb.recordset")
       sql="select * from cw_hr where id="&id&" and userid="&uid
       rs.open sql,conn,1,1
       if not rs.eof then    
          lx_hr="<table width='95%' border='0' align='center'><tr><td width='11%' height='25' align='right'>固定电话：</td><td width='38%'>"&rs("dianhua")&"</td><td width='11%' align='right'>手机：</td><td width='29%'>"&rs("shouji")&"</td></tr><tr><td height='25' align='right'>邮箱：</td><td>"&rs("email")&"</td><td align='right'>Q Q：</td><td>"&rs("qq")&"</td></tr></table>"
       else
          lx_hr="<div class='hr_err'>程序错误，请联系管理员！</div>"
       end if
       rs.close
       set rs=nothing
   Else
       lx_hr="<div class='hr_err'>&nbsp;&nbsp;登录后才能查看！<a href='"&cf_root&"user/login.asp' style='color:#FF0000'>点此登录</a></div>"
   End if
End Function

Function lx_info()
  If Session("user")<>"" then
     Set Rs=Server.CreateObject("Adodb.Recordset")
	 Rsq="Select * from "&tab&" where id="&id&" and userid="&uid
	 Rs.open Rsq,conn,1,1
	 If Not Rs.eof Then
	    lx_info="<p>联 系 人："&Rs("names")&"</p><p>联系电话："&Rs("tel")&"</p><p>联系邮箱："&Rs("email")&"</p><p>联系 QQ："&Rs("qq")&"</p><p>联系地址："&Rs("address")&"</p>"
	 Else
	    lx_info="<div class='hr_err'>程序错误，请联系管理员！</div>"	 
	 End If
  Else
     lx_info="<div class='hr_err'>&nbsp;&nbsp;登录后才能查看！<a href='"&cf_root&"user/login.asp' style='color:#FF0000'>点此登录</a></div>"
  End If
End Function

call closes()
%>
document.write("<%=html%>");