⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 trans.aspx.vb

📁 本程序修改自飞天BBS 7.0 将原来的ASP语法迁移为ASP.NET并封装成DLL ASP.NET相对ASP有更快的执行效率以及更高的并发访问量 基于ASP.NET的DLL可以运行在支持ASP
💻 VB
📖 第 1 页 / 共 2 页
字号:
' ***************************************************
' *        本程序由AspToAspX风火轮0.99转换生成      *
' *        http://Www.AspToAspX.Cn                  *
' *        Q Q :  139227536                         *
' *        QQ群:  17152722                          *
' *        MSN :  gzliangjianhua@hotmail.com        *
' *        EMail  AspToDll@vip.163.com              *
' ***************************************************
Imports Microsoft.VisualBasic
Imports System.Web
Imports System.Math
Imports System.Web.SessionState


Public Class _TRANS
    Inherits System.Web.UI.Page
    Implements IHttpHandler, AspToAspX_Interface

    Public AspToAspX_Host_Class_Object As Object

Public rssql,getstring
Public wzcount,wzrep,wzpage,wzpagecount,wzpagerep
Public i,bgcolor
Public root
Public pagestr
Public paymoney
Public defaulthome
Public swapmoney
Public integral
Public homepage
Public sql
Public rs As ADODB.Recordset
Public clubuser_money
Public clubuser_jingyuan
Public msg
Public ip
Public a
Public jingyuan
Public strsql
Public linkdb
Public ft
Public ku
Public ckiesdomain
Public conndb
Public ConnectionString
Public userinfo
Public userinfox
Public num
Public smsnum
    Public ASPX_CONN As _CONN
    Public ASPX_FTBBS_NAV As _FTBBS_NAV
    Public ASPX_INC_PUBLICFUN As _INC_PUBLICFUN
    Public ASPX_PAGEFUN As _PAGEFUN
    Public ASPX_BBSUSER As _BBSUSER
    Public ASPX_INC_BBSTAIL_HTM As _INC_BBSTAIL_HTM
#Region "..."
    Public Sub AspToAspX_InitIncludeFiles()
        ASPX_CONN = New _CONN()
        ASPX_CONN.AspToAspX_Host_Class_Object = AspToAspX_Host_Class_Object
        ASPX_CONN.AspToAspX_InitIncludeFiles()
        ASPX_FTBBS_NAV = New _FTBBS_NAV()
        ASPX_FTBBS_NAV.AspToAspX_Host_Class_Object = AspToAspX_Host_Class_Object
        ASPX_FTBBS_NAV.AspToAspX_InitIncludeFiles()
        ASPX_INC_PUBLICFUN = New _INC_PUBLICFUN()
        ASPX_INC_PUBLICFUN.AspToAspX_Host_Class_Object = AspToAspX_Host_Class_Object
        ASPX_INC_PUBLICFUN.AspToAspX_InitIncludeFiles()
        ASPX_PAGEFUN = New _PAGEFUN()
        ASPX_PAGEFUN.AspToAspX_Host_Class_Object = AspToAspX_Host_Class_Object
        ASPX_PAGEFUN.AspToAspX_InitIncludeFiles()
        ASPX_BBSUSER = New _BBSUSER()
        ASPX_BBSUSER.AspToAspX_Host_Class_Object = AspToAspX_Host_Class_Object
        ASPX_BBSUSER.AspToAspX_InitIncludeFiles()
        ASPX_INC_BBSTAIL_HTM = New _INC_BBSTAIL_HTM()
        ASPX_INC_BBSTAIL_HTM.AspToAspX_Host_Class_Object = AspToAspX_Host_Class_Object
        ASPX_INC_BBSTAIL_HTM.AspToAspX_InitIncludeFiles()
    End Sub

    Public Sub AspToAspX_UnloadIncludeFiles()
        ASPX_CONN.AspToAspX_UnloadIncludeFiles()
        ASPX_CONN = Nothing
        ASPX_FTBBS_NAV.AspToAspX_UnloadIncludeFiles()
        ASPX_FTBBS_NAV = Nothing
        ASPX_INC_PUBLICFUN.AspToAspX_UnloadIncludeFiles()
        ASPX_INC_PUBLICFUN = Nothing
        ASPX_PAGEFUN.AspToAspX_UnloadIncludeFiles()
        ASPX_PAGEFUN = Nothing
        ASPX_BBSUSER.AspToAspX_UnloadIncludeFiles()
        ASPX_BBSUSER = Nothing
        ASPX_INC_BBSTAIL_HTM.AspToAspX_UnloadIncludeFiles()
        ASPX_INC_BBSTAIL_HTM = Nothing
    End Sub

#End Region
    Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs)
        AspToAspXGlobal.Application = Application
        AspToAspXGlobal.Server = Server
        AspToAspXGlobal.Response = Response
        AspToAspXGlobal.Request = Request
        AspToAspXGlobal.Session = Session
        AspToAspX_Host_Class_Object = Me
        AspToAspX_InitIncludeFiles()
        AspToAspX_Page_Init()
        End Sub
    Public Sub AspToAspX_Page_Init()
    On Error GoTo _AspToAspX_Err
    ASPX_CONN.AspToAspX_Page_Init ( )
    ASPX_FTBBS_NAV.AspToAspX_Page_Init ( )
    ASPX_INC_PUBLICFUN.AspToAspX_Page_Init ( )
    ASPX_PAGEFUN.AspToAspX_Page_Init ( )
    ASPX_BBSUSER.AspToAspX_Page_Init ( )
    Response.Write ( "<HTML><HEAD>" & Chr ( 13 ) ) '6
    Response.Write ( "<title>交易中心</title>" & Chr ( 13 ) ) '7
    Response.Write ( "<META http-equiv=Content-Type content=text/html;charset=utf-8>" & Chr ( 13 ) ) '8
    Response.Write ( "<script language=javascript src=""inc/cookies.js""></script>" & Chr ( 13 ) ) '9
    Response.Write ( "<script>" & Chr ( 13 ) ) '10
    Response.Write ( "var stylecook = getCookie(""STYLESHOW"");" & Chr ( 13 ) ) '11
    Response.Write ( "var style;" & Chr ( 13 ) ) '12
    Response.Write ( "var strstyle;" & Chr ( 13 ) ) '13
    Response.Write ( "if(stylecook=="""")" & Chr ( 13 ) ) '14
    Response.Write ( "{" & Chr ( 13 ) ) '15
    Response.Write ( " stylecook=1;" & Chr ( 13 ) ) '16
    Response.Write ( "}" & Chr ( 13 ) ) '17
    Response.Write ( "else" & Chr ( 13 ) ) '18
    Response.Write ( "{" & Chr ( 13 ) ) '19
    Response.Write ( " stylecook++;" & Chr ( 13 ) ) '20
    Response.Write ( "}" & Chr ( 13 ) ) '21
    Response.Write ( "style=""main0""+stylecook+"".css"";" & Chr ( 13 ) ) '22
    Response.Write ( "strstyle=""<link href=\""css/""+style+""\""  rel=\""stylesheet\"" type=\""text/css\""> "";" & Chr ( 13 ) ) '23
    Response.Write ( "document.write(strstyle);" & Chr ( 13 ) ) '24
    Response.Write ( "</script>" & Chr ( 13 ) ) '25
    Response.Write ( "</HEAD>" & Chr ( 13 ) ) '26
    Response.Write ( "</head>" & Chr ( 13 ) ) '27
    Response.Write ( "<script language=""JavaScript"" src=""inc/Main.js""></script>" & Chr ( 13 ) ) '28
    Response.Write ( "<body>" & Chr ( 13 ) ) '29
    root = "../" '31
    pagestr = "" '32
    paymoney = trim ( AspToAspX_CheckIsNothing ( Request.Form ( "paymoney" ) ) ) '33
    FTBBS_HTML_MB ( ft ) '34
    defaulthome = Application ( "FTBBSMB" ) ( 31 , 0 ) '35
    wzrep = Application ( "FTBBSMB" ) ( 5 , 0 ) '36
    swapmoney = Application ( "FTBBSMB" ) ( 46 , 0 ) '37
    integral = Application ( "FTBBSMB" ) ( 47 , 0 ) '38
    homepage = ft_home ( defaulthome ) '39
    ftbbs_clubuser_id = getcookie ( "clubuser_id" ) '43
    sql = "SELECT clubuser_money,jingyuan from " & ft & "clubuser where clubuser_id=" & ftbbs_clubuser_id '44
    rs = New ADODB.Recordset ( ) '45
    rs.Open ( sql , conn , 1 , 1 ) '46
    If Not rs.EOF Then '47
        clubuser_money = AspToAspX_CheckDBNull(rs.Fields ( "clubuser_money" ) .Value) '48
        clubuser_jingyuan = AspToAspX_CheckDBNull(rs.Fields ( "jingyuan" ) .Value) '49
    Else '50
        clubuser_money = 0 '51
        clubuser_jingyuan = 0 '52
    End If '53
    If Not AspToAspX_CheckIsNumeric ( paymoney ) And AspToAspX_CheckDBNull ( paymoney ) < > EmptyString.Value Then '54
        msg = "输入错误" '55
    ElseIf AspToAspX_CheckDBNull ( paymoney ) = ""Then '56
        msg = "" '57
    ElseIf AspToAspX_CheckDBNull ( paymoney Mod swapmoney ) < > 0 Then '58
        msg = "输入金钱必须为" & swapmoney & "的整数倍" '59
    Else '60
        ip = AspToAspX_GetRequestServerVariables ( "remote_addr" ) '61
        a = paymoney / swapmoney '62
        jingyuan = a * integral '63
        If AspToAspX_CheckDBNull ( AspToAspX_CheckExpression ( clubuser_money ) - AspToAspX_CheckExpression ( paymoney ) ) < 0 Then '64
            msg = "你的金钱余额不足,你的余额为" & clubuser_money '65
        Else '66
            sql = "insert into " & ft & "ftbbs_swap_log(clubuser_id,swaptype,paymoney,getmoney,ip) values('" & ftbbs_clubuser_id & "',0,'" & paymoney & "',0,'" & ip & "')" '67
            conn.Execute ( sql ) '68
            sql = "update " & ft & "clubuser set clubuser_money=clubuser_money-" & paymoney & ",jingyuan=jingyuan+" & jingyuan & " where clubuser_id=" & ftbbs_clubuser_id '69
            conn.Execute ( sql ) '70
            AspToAspX_Response_Redirect ( "trans.aspx" ) '71
        End If '72
    End If '73
    If AspToAspX_CheckDBNull ( getcookie ( "ftbbstype" ) ) = 1 Then '74
        Response.Write ( headhtml ) '75
    End If '76
    Response.Write ( vbCrLf )
    Response.Write ( "<table width=""99%"" border=""0"" cellspacing=""0"" cellpadding=""0"" align=""center"" class=""maintbbg"">" & Chr ( 13 ) ) '78
    Response.Write ( "  <tr>" & Chr ( 13 ) ) '79
    Response.Write ( "    <td> " & Chr ( 13 ) ) '80
    Response.Write ( "      <table width=""100%"" border=0 cellpadding=2 cellspacing=1 class=""maintbbg"">" & Chr ( 13 ) ) '81
    Response.Write ( "        <tbody>" & Chr ( 13 ) ) '82
    Response.Write ( "          <tr> " & Chr ( 13 ) ) '83
    Response.Write ( "            <td height=""25"" class=""f12bg"">&nbsp;" ) '84
    Response.Write ( userinfo ) '84
    Response.Write ( "</td>" & Chr ( 13 ) ) '84
    Response.Write ( "          </tr>" & Chr ( 13 ) ) '85
    Response.Write ( "          <tr> " & Chr ( 13 ) ) '86
    Response.Write ( "            <td height=""25"" colspan=""3"" class=""maintbtr3"">&nbsp;<a href=""" ) '87
    Response.Write ( homepage ) '87
    Response.Write ( """>论坛首页</a> " & Chr ( 13 ) ) '87
    Response.Write ( "              >> <a href=""trans.aspx"">交易中心</a> >> 积分兑换&nbsp;</td>" & Chr ( 13 ) ) '88
    Response.Write ( "          </tr>" & Chr ( 13 ) ) '89
    Response.Write ( "        </tbody>" & Chr ( 13 ) ) '90
    Response.Write ( "      </table>" & Chr ( 13 ) ) '91
    Response.Write ( "    </td>" & Chr ( 13 ) ) '92
    Response.Write ( "  </tr>" & Chr ( 13 ) ) '93
    Response.Write ( "</table>" & Chr ( 13 ) ) '94
    Response.Write ( "<table cellspacing=0 cellpadding=0 width=""99%"" align=center border=0>" & Chr ( 13 ) ) '95
    Response.Write ( "  <tbody>" & Chr ( 13 ) ) '96
    Response.Write ( "    <tr> " & Chr ( 13 ) ) '97
    Response.Write ( "      <td height=5></td>" & Chr ( 13 ) ) '98
    Response.Write ( "    </tr>" & Chr ( 13 ) ) '99
    Response.Write ( "  </tbody>" & Chr ( 13 ) ) '100
    Response.Write ( "</table>" & Chr ( 13 ) ) '101
    Response.Write ( "<table width=""99%"" border=0 align=""center"" cellpadding=2 cellspacing=1 class=""maintbbg"">" & Chr ( 13 ) ) '102
    Response.Write ( "  <tbody>" & Chr ( 13 ) ) '103
    Response.Write ( "    <tr> " & Chr ( 13 ) ) '104
    Response.Write ( "      <td height=""25"" class=""f12bg"">&nbsp;<a href=""trans.aspx"">积分兑换</a>&nbsp;&nbsp;&nbsp;&nbsp;你当前金钱:" ) '105
    Response.Write ( clubuser_money ) '105
    Response.Write ( " " & Chr ( 13 ) ) '105
    Response.Write ( "        积分:" ) '106
    Response.Write ( clubuser_jingyuan ) '106
    Response.Write ( "&nbsp;&nbsp;&nbsp;&nbsp;<a href=""tenpay.aspx"">在线充值</a></td>" & Chr ( 13 ) ) '106
    Response.Write ( "    </tr>" & Chr ( 13 ) ) '107
    Response.Write ( "    <tr> " & Chr ( 13 ) ) '108
    Response.Write ( "      <td height=""80"" colspan=""3"" class=""maintbtr3""> " & Chr ( 13 ) ) '109
    Response.Write ( "        <div align=""left"">&nbsp;金钱兑换积分:<font color=red>" ) '110
    Response.Write ( swapmoney ) '110
    Response.Write ( "</font> 个单位 金钱 可兑换 <font color=red>" ) '110
    Response.Write ( integral ) '110
    Response.Write ( "</font> 个单位 积分<br><br>" & Chr ( 13 ) ) '110
    Response.Write ( "          <form name=""form1"" method=""post"" action="""">" & Chr ( 13 ) ) '111
    Response.Write ( "            &nbsp;请输入要兑换的 金钱 数量: " & Chr ( 13 ) ) '112
    Response.Write ( "            <input name=""paymoney"" type=""text"" id=""paymoney"" value=""" ) '113
    Response.Write ( msg ) '113
    Response.Write ( """ size=""30"">" & Chr ( 13 ) ) '113
    Response.Write ( "            <input type=""submit"" name=""Submit"" value=""立即兑换"">" & Chr ( 13 ) ) '114
    Response.Write ( "            (必须为 <font color=red>" ) '115
    Response.Write ( swapmoney ) '115
    Response.Write ( "</font> 的整数倍) " & Chr ( 13 ) ) '115
    Response.Write ( "          </form>" & Chr ( 13 ) ) '116
    Response.Write ( "        </div></td>" & Chr ( 13 ) ) '117
    Response.Write ( "    </tr>" & Chr ( 13 ) ) '118
    Response.Write ( "   </tbody>" & Chr ( 13 ) ) '119
    Response.Write ( "</table>" & Chr ( 13 ) ) '120
    Response.Write ( "<table cellspacing=0 cellpadding=0 width=""99%"" align=center border=0>" & Chr ( 13 ) ) '121
    Response.Write ( "  <tbody>" & Chr ( 13 ) ) '122
    Response.Write ( "    <tr> " & Chr ( 13 ) ) '123
    Response.Write ( "      <td height=5></td>" & Chr ( 13 ) ) '124
    Response.Write ( "    </tr>" & Chr ( 13 ) ) '125
    Response.Write ( "  </tbody>" & Chr ( 13 ) ) '126
    Response.Write ( "</table>" & Chr ( 13 ) ) '127
    Response.Write ( "<table width=""99%"" border=0 cellpadding=2 cellspacing=1 class=""maintbbg"" align=""center"">" & Chr ( 13 ) ) '128
    Response.Write ( "  <tbody>" & Chr ( 13 ) ) '129
    Response.Write ( "    <tr align=left class=f12> " & Chr ( 13 ) ) '130
    Response.Write ( "      <td height=""27"" colspan=""7"" class=""f12bg"">&nbsp;积分交易记录</td>" & Chr ( 13 ) ) '131
    Response.Write ( "    </tr>" & Chr ( 13 ) ) '132
    Response.Write ( "    <tr align=middle class=f12> " & Chr ( 13 ) ) '133
    Response.Write ( "      <td width=""4%"" height=""28"" class=""maintbtr1"">选择</td>" & Chr ( 13 ) ) '134
    Response.Write ( "      <td width=""4%"" class=""maintbtr1"">序号</td>" & Chr ( 13 ) ) '135
    Response.Write ( "      <td width=""19%"" class=""maintbtr1"" >支出金钱</td>" & Chr ( 13 ) ) '136
    Response.Write ( "      <td width=""19%"" class=""maintbtr1"" >得到金钱</td>" & Chr ( 13 ) ) '137
    Response.Write ( "      <td width=""19%"" class=""maintbtr1"" >IP</td>" & Chr ( 13 ) ) '138
    Response.Write ( "      <td width=""19%"" class=""maintbtr1"" >时间</td>" & Chr ( 13 ) ) '139
    Response.Write ( "      <td width=""16%"" class=""maintbtr1"" >兑换方式</td>" & Chr ( 13 ) ) '140
    Response.Write ( "    </tr>" & Chr ( 13 ) ) '141
    Response.Write ( "<form name=""selectform"" method=""post"" action=""deltrans.aspx"" style=""MARGIN-TOP: 0px;margin-bottom:0px"">" & Chr ( 13 ) ) '142
    Response.Write ( "    <input type=""hidden"" name=""op"" value=""选择删除"">" & Chr ( 13 ) ) '143
    Response.Write ( " <script language=""JavaScript"">" & Chr ( 13 ) ) '144
    Response.Write ( "  <!--" & Chr ( 13 ) ) '145
    Response.Write ( "  function select_pl_submit(optype){" & Chr ( 13 ) ) '146
    Response.Write ( "" & Chr ( 9 ) & "var f=document.forms[""selectform""]" & Chr ( 13 ) ) '147
    Response.Write ( "" & Chr ( 9 ) & "f.op.value=optype" & Chr ( 13 ) ) '148
    Response.Write ( "" & Chr ( 9 ) & "f.submit()" & Chr ( 13 ) ) '149
    Response.Write ( "  }" & Chr ( 13 ) ) '150
    Response.Write ( "  //-->" & Chr ( 13 ) ) '151
    Response.Write ( "  </script>" & Chr ( 13 ) ) '152
    strsql = "SELECT * from " & ft & "ftbbs_swap_log where clubuser_id=" & ftbbs_clubuser_id & " order by id desc" '154
    rs = New ADODB.Recordset ( ) '155
    rs.Open ( strsql , conn , 1 , 1 ) '156
    If Not rs.EOF Then '157
        wzpage = AspToAspX_CInt ( Request ( "page" ) ) '159
    If AspToAspX_Len ( wzpage ) = 0 Or AspToAspX_CheckDBNull ( wzpage ) = 0 Then
wzpage = 1
End If
    '161
        rs.PageSize = wzrep '162
        rs.AbsolutePage = wzpage '163
        wzpagecount = rs.PageCount '164
        wzcount = rs.RecordCount '165
        For i = 0 To Val ( wzrep ) - 1 '166
        If rs.EOF Then
Exit For
End If
    '167
            Response.Write ( vbCrLf )

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -