/Space.asp
ASP | 110 lines | 101 code | 1 blank | 8 comment | 11 complexity | 47d936ad1fbe91e1a02d2a4e3ef1d148 MD5 | raw file
- <!--#include file="include/skin.asp"-->
- <!--#include file="include/Function.asp"-->
- <!--#include file="include/user_info.asp"-->
- <!--#include file="ubb/ubb.asp"-->
- <%
- dim user_id,tag_name,num,now_url,navstr,o,ostr,p_url
- user_id =trim(request.QueryString("user_id"))
- o=Trim(Request.QueryString("o"))
- if not int_true(user_id) then
- response.Write "??id??????":response.End()
- else
- user_id=int(user_id)
- if user_id=login_ID then call format_redirect("MySpace.asp")
- now_url="Space.asp?user_id="&user_id&"&"
- p_url="Space.asp?user_id="&user_id&"&"
- tag_name=Trim(Request.QueryString("tag_name"))
- if not var_null(tag_name) then '????
- tag_name=king51_dig.code_html(tag_name,1,20)
- p_url=now_url&"&tag_name="&tag_name&"&"
- tagstr = " AND ((article.tag) = '"&tag_name&"')"
- navstr="??:<a href=""list_tag.asp?tagname="&server.urlencode(tag_name)&""">"&tag_name&"</a>"
- ' else
- ' navstr="????"
- end if
- end if
- if not var_null(o) then
- p_url=now_url&"&o="&o
- end if
- call order_nav
- '????????
- dim User_CoolName,User_Face,User_Sex,User_Money, User_PostNum, User_counter,User_Demo, User_ad
- sql="select User_CoolName,User_Face,User_Sex,User_Money,User_PostNum,User_counter,User_Demo,User_ad from user_data where id="&user_id
- set rs=king51_dig.exec(sql,1)
- if not rs.eof then
- User_CoolName=rs(0):User_Face=rs(1):User_Sex=rs(2):User_Money=rs(3)
- User_PostNum=rs(4):User_counter=rs(5):User_demo=rs(6):User_ad=rs(7)
- end if
- rs.close : Set Rs = Nothing
-
- navstr="<a href=""Space.asp?user_id="&user_id&""">"&User_CoolName&"???</a>"&navstr
- tit=User_CoolName&"???-"&tag_name&"-????"
- call web_head()
- response.Write "<div id=""contain"">"&_
- vbcrlf&"<div class=""left"">"&left_nav&"<dl>"
- '??????
- dim tagstr,orderstr,view_url,art_data,art_dataNum
- dim id,c_id,topic,pic,word,tags,tim,counter,Fav_Num,hit_num,revert_num,c_name
- sql="SELECT article.id, article.c_id, article.topic, article.pic, article.word, article.tag, article.tim, article.counter, article.Fav_Num, article.hit_num, article.revert_num, class.c_name FROM class INNER JOIN article ON class.ID = article.c_id where article.user_id="&user_id&tagstr&" order by "&ostr&" desc"
- set rs=king51_dig.exec(sql,1)
- if not rs.eof then
- art_data=rs.getrows
- art_dataNum=ubound(art_data,2) '??????????
- rs.close : Set Rs = Nothing
- '//?asp???getrows?????????
- dim j,iStop,page
- page=Trim(Request.QueryString("page"))
- if Not int_true(page) then
- page=1 '??????
- j = 0
- iStop=web_dim(26)-1 '?????
- else
- if page<1 then : page=1
- j = (CInt(page)-1)*web_dim(26)
- iStop=(web_dim(26)*page)-1
- end if
- if iStop>art_dataNum then
- iStop=art_dataNum
- end if
- '//----------------------------
- For i = j to iStop
- id=art_data(0,i) : c_id=art_data(1,i) : topic=art_data(2,i):pic=art_data(3,i) : word=art_data(4,i):tags=art_data(5,i)
- tim=art_data(6,i) : counter=art_data(7,i) : Fav_Num=art_data(8,i): hit_num=art_data(9,i):revert_num=art_data(10,i)
- c_name=art_data(11,i)
- topic=king51_dig.code_html(topic,1,78)
- word=king51_dig.code_html(word,2,web_dim(27))
- view_url="view.asp?article_id="&id
- if not var_null(tags) then tags="<img src="""&web_dim(11)&"tag.png""> <a href='list_tag.asp?tagname="&server.urlencode(tags)&"'>"&tags&"</a>"
- response.Write vbcrlf&"<dd class=""info"" id=""Src_Info"&id&""">"&_
- vbcrlf&"<ul class=""left"">"&_
- vbcrlf&"<li class=""dig1"" id=""Src_HitNum"&id&""">"&hit_num&"</li>"&_
- vbcrlf&"<li class=""dig2"" id=""art_id"&id&""">"&kdig.Is_Hit(id)&"</li>"&_
- vbcrlf&"</ul>"&_
- vbcrlf&"<ul class=""right"">"&_
- vbcrlf&"<h1><a href="""&view_url&""" >"&topic&"</a></h1>"&_
- vbcrlf&"<li class=""postinfo"">"&fav_list&" ???"&king51_dig.time_type(tim,1)&"</li>"&_
- vbcrlf&"<li class=""content clear"">"&_
- vbcrlf&"<table width=""auto"" height=""auto"" cellspacing=""0""><tr>"&_
- vbcrlf&"<td>"&Ubbcode(word)&" <a href="""&view_url&""" title=""?????"&topic&"?????""><font style="" font-weight: normal"">??»</font></a> ("&counter&" ???)</td>"&_
- vbcrlf&"</tr></table></li>"&_
- vbcrlf&"<li class=""count_info""><a href="""&view_url&"#Revert"">"&revert_num&" ???</a> <img src="""&web_dim(11)&"fav.gif""> "&add_fav(id)&" <img src="""&web_dim(11)&"tag.png""> <a href=""list.asp?c_id="&c_id&""" title=""?????????"">"&c_name&"</a> "&tags&"</li></ul></dd>"
- next
- erase art_data
- '//----------
- response.Write page_view
- '//-----------
- else
- rs.close : Set Rs = Nothing
- response.write vbcrlf&"<h1>???????????????</h1><div>1??????????,?????????<br>2????????????????????????<br />3???????????????????????<br /><br /><a href=""user.asp""><b>??????????????</b></a></div>"
- end if
- if islogin then call addvisit
- response.Write"<dl></div>"&_
- vbcrlf&"<div class=""sidebar"">"
- user_box
- fav_box
- tag_box(user_id)
- visit_box
- response.Write"</div></div>"
- call king51_dig.exec("update user_data set User_counter=User_counter+1 where ID="&user_id,0)
- call web_end()
- %>