不能ASP图像组件来生成图像的ASP计数器程序(二)

2016-01-29 17:59 3 1 收藏

不能ASP图像组件来生成图像的ASP计数器程序(二),不能ASP图像组件来生成图像的ASP计数器程序(二)

【 tulaoshi.com - ASP 】

  -----------------------counter.asp---------------------
<%user=request.querystring("user")%
<!--#include file="header"--
<%
set fsFilesys=CreateObject("Scripting.FileSystemObject")
set myText=fsFilesys.OpenTextFile(Server.MapPath("/explorer/")&"/counter/txt/"&user&".ddd")
counter=myText.ReadLine
myText.close
counter=counter+1
set myText=fsFilesys.CreateTextFile(Server.MapPath("/explorer/")&"/counter/txt/"&user&".ddd",true)

myText.WriteLine(counter)
myText.close %
<%
dim a(512)
dim data1(10,8,8)
data1(8,0,0)=0
data1(8,0,1)=0
data1(8,0,2)=0
data1(8,0,3)=0
data1(8,0,4)=0
data1(8,0,5)=0
data1(8,0,6)=0
data1(8,0,7)=0

data1(8,1,0)=0
data1(8,1,1)=1
data1(8,1,2)=1
data1(8,1,3)=1
data1(8,1,4)=1
data1(8,1,5)=1
data1(8,1,6)=1
data1(8,1,7)=1

data1(8,2,0)=0
data1(8,2,1)=1
data1(8,2,2)=0
data1(8,2,3)=0
data1(8,2,4)=0
data1(8,2,5)=0
data1(8,2,6)=0
data1(8,2,7)=1

data1(8,3,0)=0
data1(8,3,1)=1
data1(8,3,2)=0
data1(8,3,3)=0
data1(8,3,4)=0
data1(8,3,5)=0
data1(8,3,6)=0
data1(8,3,7)=1

data1(8,4,0)=0
data1(8,4,1)=1
data1(8,4,2)=1
data1(8,4,3)=1
data1(8,4,4)=1
data1(8,4,5)=1
data1(8,4,6)=1
data1(8,4,7)=1

data1(8,5,0)=0
data1(8,5,1)=1
data1(8,5,2)=0
data1(8,5,3)=0
data1(8,5,4)=0
data1(8,5,5)=0
data1(8,5,6)=0
data1(8,5,7)=1

data1(8,6,0)=0
data1(8,6,1)=1
data1(8,6,2)=0
data1(8,6,3)=0
data1(8,6,4)=0
data1(8,6,5)=0
data1(8,6,6)=0
data1(8,6,7)=1

data1(8,7,0)=0
data1(8,7,1)=1
data1(8,7,2)=1
data1(8,7,3)=1
data1(8,7,4)=1
data1(8,7,5)=1
data1(8,7,6)=1
data1(8,7,7)=1

data1(0,0,0)=0
data1(0,0,1)=0
data1(0,0,2)=0
data1(0,0,3)=0
data1(0,0,4)=0
data1(0,0,5)=0
data1(0,0,6)=0
data1(0,0,7)=0

data1(0,1,0)=0
data1(0,1,1)=1
data1(0,1,2)=1
data1(0,1,3)=1
data1(0,1,4)=1
data1(0,1,5)=1
data1(0,1,6)=1
data1(0,1,7)=1

data1(0,2,0)=0
data1(0,2,1)=1
data1(0,2,2)=0
data1(0,2,3)=0
data1(0,2,4)=0
data1(0,2,5)=0
data1(0,2,6)=0
data1(0,2,7)=1

data1(0,3,0)=0
data1(0,3,1)=1
data1(0,3,2)=0
data1(0,3,3)=0
data1(0,3,4)=0
data1(0,3,5)=0
data1(0,3,6)=0
data1(0,3,7)=1

data1(0,4,0)=0
data1(0,4,1)=1
data1(0,4,2)=0
data1(0,4,3)=0
data1(0,4,4)=0
data1(0,4,5)=0
data1(0,4,6)=0
data1(0,4,7)=1

data1(0,5,0)=0
data1(0,5,1)=1
data1(0,5,2)=0
data1(0,5,3)=0
data1(0,5,4)=0
data1(0,5,5)=0
data1(0,5,6)=0
data1(0,5,7)=1

data1(0,6,0)=0
data1(0,6,1)=1
data1(0,6,2)=0
data1(0,6,3)=0
data1(0,6,4)=0
data1(0,6,5)=0
data1(0,6,6)=0
data1(0,6,7)=1

data1(0,7,0)=0
data1(0,7,1)=1
data1(0,7,2)=1
data1(0,7,3)=1
data1(0,7,4)=1
data1(0,7,5)=1
data1(0,7,6)=1
data1(0,7,7)=1


data1(1,0,0)=0
data1(1,0,1)=0
data1(1,0,2)=0
data1(1,0,3)=0
data1(1,0,4)=0
data1(1,0,5)=0
data1(1,0,6)=0
data1(1,0,7)=0

data1(1,1,0)=0
data1(1,1,1)=0
data1(1,1,2)=0
data1(1,1,3)=0
data1(1,1,4)=0
data1(1,1,5)=0
data1(1,1,6)=1
data1(1,1,7)=1

data1(1,2,0)=0
data1(1,2,1)=0
data1(1,2,2)=0
data1(1,2,3)=0
data1(1,2,4)=0
data1(1,2,5)=0
data1(1,2,6)=1
data1(1,2,7)=1

data1(1,3,0)=0
data1(1,3,1)=0
data1(1,3,2)=0
data1(1,3,3)=0
data1(1,3,4)=0
data1(1,3,5)=0
data1(1,3,6)=1
data1(1,3,7)=1

data1(1,4,0)=0
data1(1,4,1)=0
data1(1,4,2)=0
data1(1,4,3)=0
data1(1,4,4)=0
data1(1,4,5)=0
data1(1,4,6)=1
data1(1,4,7)=1

data1(1,5,0)=0
data1(1,5,1)=0
data1(1,5,2)=0
data1(1,5,3)=0
data1(1,5,4)=0
data1(1,5,5)=0
data1(1,5,6)=1
data1(1,5,7)=1

data1(1,6,0)=0
data1(1,6,1)=0
data1(1,6,2)=0
data1(1,6,3)=0
data1(1,6,4)=0
data1(1,6,5)=0
data1(1,6,6)=1
data1(1,6,7)=

来源:http://www.tulaoshi.com/n/20160129/1503865.html

延伸阅读
标签: ASP
      很多的网站都有记数器,用来记录网站的访问量,这给网站管理员即时了解本网站的运行及访问情况提供了很多的方便。笔者研究过很多用ASP编写的计数器程序,发现大部份都是在一个访客访问站点的时候就打文本文件或数据库,读取以前的计数值进行加1,然后再写入文件,若网站访问量很大,可能会对系统造成很大的负担,那...
标签: ASP
  网页计数器DIY 随着网络大行其道,网页计数器也流行起来。事实上大多数网站均有网页计数器,用以反映该网站的访问量。计数器的来源很广,Frontpage等网页编辑器自带了网页计数器,有的站点也提供免费的计数器下载。其实熟悉了ASP编程后,自己做一个计数器很容易。下面介绍一种实现方法。 计数器原理是:在第一次使用网页时置初始值1,以...
标签: PHP
  1)文本计数器 <?php $countfile="/count.txt";  //设置保存数据的文件 if (!file_exists($countfile)){//判断文件是否存在 exec( "echo 0 $countfile"); } $fp = fopen($countfile,"rw"); $length=filesize($countfile); $num = fgets($fp,$length); $num += 1; exec( "rm -rf $...
标签: vb
By Steven Smith from aspalliance.com Yknow, theres this really cool library in .NET for dynamically creating images on the fly. However, this article has nothing to do with that, so if thats what youre looking for, stop now. What this article is about is very simple -- how to use a single line of code (via a compo...
标签: PHP
现在,上网的人越来越多,许多网友尝试着制作自己的主页,访客计数器是必不可少的一部分。虽然很多网站提供免费的计数器,可毕竟不是自己亲手制作的?有的朋友可能认为它很难,不敢去尝试,其实有了PHP这个工具,它并不难,甚至可以说它很容易。   首先,让我来谈一谈访客计数器的思路:一位访问者浏览此页,服务器(如Apac...

经验教程

854

收藏

96
微博分享 QQ分享 QQ空间 手机页面 收藏网站 回到头部