易截截图软件、单文件、免安装、纯绿色、仅160KB

asp分页代码

 <%'开始分页
    Const MaxPerPage=25
       dim totalPut  
       dim CurrentPage
       dim TotalPages
       dim j
       dim sql
        if Not isempty(request("page")) then
          currentPage=Cint(request("page"))
       else
          currentPage=1
       end if
   set rs=server.createobject("adodb.recordset")
      rs.open "*",conn,1,1
      if rs.eof And rs.bof then
           Response.Write "<p align='center' class='in'> 您还没有添加活动!</p>"
       else
       totalPut=rs.recordcount
          if currentpage<1 then
              currentpage=1
          end if
          if (currentpage-1)*MaxPerPage>totalput then
         if (totalPut mod MaxPerPage)=0 then
           currentpage= totalPut \ MaxPerPage
         else
            currentpage= totalPut \ MaxPerPage + 1
         end if
          end if
           if currentPage=1 then
     &n


相关文档:

二. ASP NET MVC

1.Controller类引用的View会自动的对应到Views\XXX目录中寻找。
其中Views\Shared存放共享的试图模板。
搜索顺序:
首先搜索\Views\[Controller],如果找不到,再开始查找Views\Shared子目录。
2.
建议:视图的模板名称和Action引用的方法名称相同。
这样的话,开发人员就可以省略View Template的名称。
比如:retur ......

ASP连接MySQL数据库的方法

ASP连接MySQL数据库的方法
 
 
 
ASP等语言连接mysql数据库,可以通过安装mysql的ODBC驱动,通过配置ODBC数据源,连接并操作数据库。
mysql odbc 3.51版
下载地址:
http://dev.mysql.com/downloads/connector/odbc/3.51.html
<%
'测试读取MySql数据库的内容
strconnection="driver={mysql odb ......

2、纯ASP代码生成图表函数——柱图

2、纯ASP代码生成图表函数——柱图
<%
dim total(12,2)
total(1,1)=56
total(2,1)=7
total(3,1)=-7
total(4,1)=0
total(5,1)=16
total(6,1)=10
total(7,1)=14
total(8,1)=7
total(9,1)=9
total(10,1)=7
total(11,1)=11
total(12,1)=14
total(1,2)="地理"
total(2,2)="化学"
total(3,2)="历史 ......
© 2009 ej38.com All Rights Reserved. 关于E健网联系我们 | 站点地图 | 赣ICP备09004571号