📄 read.asp
字号:
<html>
<head>
<TITLE>txtread.asp</TITLE>
</head>
<body bgcolor="#FFFFFF">
<%
whichfile=server.mappath("test.txt")
Set fs = CreateObject("Scripting.FileSystemObject")
Set thisfile = fs.OpenTextFile(whichfile, 1, False)
'上述参数1表示只读,False表示如文件不存在,则不能创建,后面有详细解释
counter=0
do while not thisfile.AtEndOfStream
counter=counter+1
thisline=thisfile.readline
response.write thisline & "<br>"
loop
thisfile.Close
set thisfile=nothing
set fs=nothing
%>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -