5 C: B1 d9 o' D5 x! T1 C+ iSub echoContent() , o6 T4 ]# h5 F0 N/ `5 x0 B* A0 b) r( y* i0 v5 f! b4 M
dim id% s; L( ?$ c/ G5 }
7 h- j6 X' k4 V7 ?& b: X id=getForm("id","get")9 d6 Q0 W h1 I
) }. I+ ?. i# e 7 F! Q6 i# k2 T) r2 N4 N# e8 D3 @% Y2 Z; p6 R5 [
if isnul(id) or not isnum(id) then alertMsgAndGo "请选择产品!","-1" - i. t) |0 V$ t: D3 V: R. ^; M8 E & b1 \# I+ h1 r. ~ 2 l8 T; d) v5 [# O; D4 ]/ \8 k9 @2 z# U/ U3 d$ l6 K
dim templateobj,channelTemplatePath : set templateobj = mainClassobj.createObject("MainClass.template")/ q- K0 S( q- y: m: G
. i# b8 K2 O1 U; z0 p3 p
dim typeIds,rsObj,rsObjtid,Tid,rsObjSmalltype,rsObjBigtype,selectproduct3 b; y4 G: P; z9 X7 D
# S1 X, C4 d; e Dim templatePath,tempStr( @/ s- }. \4 m$ P! x1 @- x
+ {! K( S* z! Q' Y, ~. L+ O2 { templatePath = "/"&sitePath&"templates/"&defaultTemplate&"/"&htmlFilePath&"/productbuy.html" 8 Z! y e9 r6 _3 b2 R ( F( f/ P8 j( w) C( d; [) X1 e2 v1 @& S8 {) w5 l
+ s7 u. Y. T& h' E set rsObj=conn.Exec("select title from aspcms_news where newsID="&id,"r1")# O! O5 k; _! P$ V2 s/ i
6 H9 v! P4 K7 Y' e) N5 a selectproduct=rsObj(0)# [( E ]! c; b [: j4 o& X: |
1 d* C/ j; z5 B$ x- A7 Z9 P7 ^ ( m: H. U* {$ o3 O6 V * }4 W4 X ?6 Y& n! p( p. @5 B+ ~ Dim linkman,gender,phone,mobile,email,qq,address,postcode % D) ^8 w. e1 D9 a 6 ~4 |" Y4 A$ @0 G. T1 M if isnul(rCookie("loginstatus")) then wCookie"loginstatus",0 * u/ U, \% t! d3 ?: |- E7 Q0 e0 d' s# C6 n3 G
if rCookie("loginstatus")=1 then 4 ? a; q9 v. r7 S
0 B. @: U6 u; ? set rsObj=conn.Exec("select * from aspcms_Users where UserID="&trim(rCookie("userID")),"r1") 2 C" r' }8 S/ k4 F5 `! |7 r! O: I- k: a, w. `* D K8 N
linkman=rsObj("truename")0 J2 p) |' `* }3 E# x
2 A4 N1 ?2 Y" U( _
gender=rsObj("gender") 9 ~! W3 }0 |; ]3 J& \' ?& O9 W7 e+ J# H7 |4 L
phone=rsObj("phone") 6 L) V$ W, i8 Z, z' S0 J) S. ^9 \7 y2 R# C
mobile=rsObj("mobile")7 w: |% O( h/ B; Y! |0 i6 U
2 V0 @& }) d/ J: k email=rsObj("email")/ O9 x3 Q# W a- E& T8 t' N
, {0 G' C1 f, E/ H9 s5 T W4 \" @% e qq=rsObj("qq") 7 v6 P# _/ P8 [, l( t+ r9 r( r6 A& p4 C+ y
address=rsObj("address") e4 p; P2 ~5 k. d# X
+ ^- S3 d3 c) C# U$ i* P
postcode=rsObj("postcode") " t9 q6 P M$ C* ^; @: t+ Y/ Q 7 C* K+ ]0 {& \9 M2 d+ e else ) H1 E; }- h$ n4 u- |9 `6 r: t9 J/ S8 p$ ^3 q
gender=1 ) G6 Q; `' ]" V& @8 U% `0 P+ G4 U
end if 8 V- @& ^$ e/ B% r* S 1 M6 D+ @5 f' w) W s rsObj.close() ' L' y+ U. u5 w8 _ ( l% ]3 p" O( B. m! g: o 6 }8 F* k1 S6 `$ b # G, X0 }3 V& W, w with templateObj : H' r( `, q4 l# h: y6 C# y+ C/ h ; _+ e$ F3 S* s: [! L; d .content=loadFile(templatePath) , c$ Q4 s% g s. n0 }# Z; C$ p" h- f+ h+ @
.parseHtml()$ r( q0 A0 Q4 {! y
8 @3 E2 E" ?7 x9 D4 O+ ^ d* u/ d
.content=replaceStr(.content,"{aspcms:selectproduct}",selectproduct)' O3 X7 g- f2 ?3 V
2 _4 ~ e% f7 I: P8 u .content=replaceStr(.content,"[aspcms:linkman]",linkman) % K# Z: |+ a6 _3 |" N+ ~0 z# _7 {% Y0 N8 z) f3 c9 U* Y
.content=replaceStr(.content,"[aspcms:gender]",gender) 7 g6 r7 e, ^. s* Q- H8 y7 v7 b. s
+ {2 U7 {6 d" Q$ X) w' p. p
.content=replaceStr(.content,"[aspcms:phone]",phone) - Q x6 n" r* q' V: O2 w0 ?" `& O. U7 x M
.content=replaceStr(.content,"[aspcms:mobile]",mobile) 0 _5 { j9 Z. Z6 Q6 [0 C4 F% }