%
Response.AddHeader "P3P","CP=""CAO PSA OUR"""
visitedc=request.cookies("visited")
if len(Request.QueryString("id"))>3 or len(request.cookies("actref"))>2 then
if len(request.cookies("actref"))>2 then
t_s11=request.cookies("actref")
end if
if len(Request.QueryString("id"))>3 then
t_s11=Request.QueryString("id")
end if
if not isnumeric(t_s11) then
t_s11="15750"
end if
t_s11=clng(t_s11)
if clng(t_s11)="17072" then
if second(now()) mod 30=0 then
else
response.write "
"
response.end
end if
end if
set rs = server.CreateObject("ADODB.recordset")
user="select * from master where userid=" & Clng(t_s11)
rs.open user,cm_cb
if rs.eof and rs.bof then
t_s11="15750"
rs.close
set rs=nothing
set rs = server.CreateObject("ADODB.recordset")
user="select * from master where userid=" & Clng(t_s11)
rs.open user,cm_cb
hid=rs("hopid")
expirydate=rs("expirydate")
fname=rs("first_name") & " " & rs("last_name")
rs.close
set rs=nothing
end if
hid=rs("hopid")
expirydate=rs("expirydate")
fname=rs("first_name") & " " & rs("last_name")
rs.close
set rs=nothing
if instr(request.servervariables("script_name"),"theme1") then
Version="Version 2.0"
elseif instr(request.servervariables("script_name"),"theme2") then
Version="Version 3.0"
elseif instr(request.servervariables("script_name"),"theme3") then
Version="Version 4.0"
elseif instr(request.servervariables("script_name"),"theme4") then
Version="Version 5.0"
elseif instr(request.servervariables("script_name"),"theme5") then
Version="Version 6.0"
end if
set rs = server.CreateObject("ADODB.recordset")
user="select image_size,storefront_nickname,footer_check,sf_title,css,no_of_products, bottom_script,side_script,right_side_script ,sf_meta_descr,sf_meta_kw,show_rank,show_price,product_selection from storefront where theme=1 and userid="& Clng(t_s11)
rs.open user,cm_cb
if rs.bof and rs.eof then
response.write "You have not yet set up the storefront " & version & "!
You may login to your members area and may configure the Storefront " & version &_
vbcrlf & "
Click here to login"
cm_cb.close
set cm_cb=nothing
response.end
end if
sftt=rs("sf_title")
if isnull((sftt)) or len(sftt)<2 then
response.write "You have NOT configured your Storefront " & version &" correctly. You have to save your storefront after any change/reset in configuration."
cm_cb.close
set cm_cb=nothing
response.end
end if
if isnull((hid)) or len(hid)<2 then
response.write "You have not yet updated your Clickbank ID on your profile. Please login to your members area and go to Settings link to update."
cm_cb.close
set cm_cb=nothing
response.end
end if
if expirydate>=date() then
Response.cookies("alternate")=(hid)
else
Response.Cookies("userid")="go4buck"
Response.cookies("alternate")="go4buck"
response.write "
"& fname & "" & _
",
Your StoreFront " & version & " will be activated automatically after your upgrade to PRO and this red color box " & _
"will be disabled. And you will have your Clickbank ID : '"&hid&"' embedded on all of the product links." & _
" " end if
Response.Cookies("userid")=hid
response.Cookies("actref")=clng(t_s11)
rs.close
set rs=nothing
hop=request.cookies("userid")
actref=request.cookies("actref")
alter_hop=request.cookies("alternate")
else
if len(request.cookies("userid"))>2 then
else
Response.Cookies("userid")="go4buck"
response.Cookies("actref")="15750"
Response.cookies("alternate")="go4buck"
end if
hop=request.cookies("userid")
actref=request.cookies("actref")
alter_hop=request.cookies("alternate")
end if
if Request.QueryString("plugin")="yes" then
plugin="yes"
response.cookies("plugin")="yes"
else
if Request.QueryString("plugin")="no" then
response.cookies("plugin")="no"
plugin="no"
end if
if request.cookies("plugin")="yes" then
plugin="yes"
end if
end if
if session("ipss")="" or session("ipss")=" " or isnull(session("ipss")) or len(session("ipss"))<5 then
t_ip="yes"
else
t_ip="no"
end if
If robot_check(Request.ServerVariables("HTTP_USER_AGENT")) ="human" and t_ip ="yes" Then
session("ipss")=request.servervariables("REMOTE_HOST")
set rs = server.CreateObject("ADODB.recordset")
currdate=(year(date()) & "-" & month(date()) & "-" & day(date()) )
channel="fromclickbankmall"
user="select userid from clicks where userid=" & actref & " and clickdate='" & currdate & "' and channel='" & channel & "'"
'response.write currdate & " " & member & " " & user
'rs.CursorLocation = adUseClient
rs.open user,cm_cb
if rs.eof and rs.bof then
s="insert into clicks values(" & actref& ",'" & currdate & "','" & channel &"',1,0)"
'response.write s
cm_cb.execute s
else
s="update clicks set impression=impression+1 where userid=" & actref & " and clickdate='" & currdate & "' and channel='" & channel &"'"
'response.write s
cm_cb.execute s
end if
rs.close
set rs=nothing
end if
%>