%@ Language=VBScript %>
<%
cno = Request("cardnum")
varname = Request.Form("name")
varage = Request.Form("age")
If cno="FLB31" and varage="" Then
path="./dyflashcard.asp?cardnum=FLB31"
response.Redirect(path)
End if
%>
Orangepie Free Fun E-Cards
<%
function getdate(seldate)
dim crdate,lastDate,strSelect
crdate=date()
lastDate=DATEADD("m",2,date())
strSelect=""
getdate=strSelect
end function
' read all the user parameters and the cardnum
'* If cno is null then redirect to error page
strSelectDate=getdate(date())
function CheckForFreeCat(strCno)
' checking for the free category
Set SQLConn = Server.CreateObject("ADODB.Connection")
SQLConn.open "filedsn=c:\inetpub\orangepie\dsn\sqldb.dsn","orangepie","orangepie"
set rs=server.CreateObject("adodb.recordset")
sql="select a.* from tblFreeCategories a,flashcarddetail b where a.catid=b.catid and b.cardnum='"&strCno&"'"
rs.Open sql,SQLConn,adOpenForwardOnly,adLockReadOnly
if rs.EOF then
val=false
else
val=true
end if
rs.Close
set rs=nothing
set SQLConn=nothing
CheckForFreeCat=val
' return true if free , false otherwise
end function
Set Conn = Server.CreateObject("ADODB.Connection")
Conn.open "filedsn=c:\inetpub\orangepie\dsn\sqldb.dsn","orangepie","orangepie"
SQL = "SELECT * FROM flashcarddetail WHERE cardnum='" & cno & "'"
'response.Write "SQL:" & sql & " "
'SQL = "SELECT m.category,d.* FROM carddetail d,cardmaster m WHERE d.catid=m.catid and cardnum='" & cno & "'"
Set cardgalary = Conn.Execute(SQL)
'category=cardgalary("category")
catid=cardgalary("catid")
isfree=CheckForFreeCat(cno)
'Response.Write login
login=session("login")
if login="1" then
login="Yes"
usrid=session("usrid")
session("usrid")=usrid
session("login")="1"
send = Session("from_name")
smail = Session("from_mail")
' referesh session variavles
Session("from_name")=send
Session("from_mail")=smail
else
login="No"
end if
bimg=cardgalary("bimg")
bcolor=cardgalary("pagecolor")
'bsound=cardgalary("bsound")
'cardcat=cardgalary("category")
varwidth = cardgalary("width")
varheight = cardgalary("height")
varswfpath = cardgalary("swfpath")
'Response.Write "cno:" & cno & " "
If ucase(cno)="FLB31" Then
if NOT varage="" then
varswfpath = "./images/Birthday/flash/b31a.swf?name="&varname&"&age="&varage '/// For Dynamic Flash Card
end if
End if
'Response.Write "swf:" & varswfpath & " "
varloopval = cardgalary("loopval")
varpagecolor = cardgalary("pagecolor") 'bgcolor of the html body
varbgcolorval = cardgalary("bgcolorval") 'bgcolor of the card
varObTag = " "
Conn.Close
set Conn=nothing
'set cardgalary=nothing
'bsound="http://www.astrosoftnet.com/orsound/"&bsound
if bimg="none" then
cardbg="bgcolor=#"& bcolor
else
cardbg="background=" & bimg
end if
%>
leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">