I am simply playing with it. If you do not have this online practice, write it. The code is very simple. You can use it for reference.
Code Background: A Website access record made by myself. Because of the huge access volume and small virtual space, no database is used. CSV storage, in order to make it easy to read files without downloading them each time, this ASP is used to help read files.
. CSV file Introduction: http://baike.baidu.com/view/468993.htm
The algorithm is to use ASP code to open a text file (CSV), split a row into an array using the split function, and output one by one. After each row ends, a line feed mark is output.
<HTML> <title> Read records </title> <body> <p> CSV records are read as follows: </P> <p> <% set FS = server. createobject ("scripting. fileSystemObject ") set f = FS. opentextfile (server. mappath ("record.csv"), 1) 'Open the text file response. write ("<Table border =" "1"> ") 'creates the do while F table. atendofstream = falsestr = f. readlinesplitstr = Split (STR, ",") 'splits the response string of a row. write ("<tr>") 'creates a table row for I = 0 to ubound (splitstr) response. write ("<TD>") 'creates the table column response. write splitstr (I) response. write ("</TD>") nextresponse. write ("</tr>") loopresponse. write ("</table>") F. closeset F = nothingset FS = nothing %> </P> </body>
Just a few simple lines of code are made to give a reference to beginners like me.
Reference page: http://icyfox.web-150.com/read.asp
This is webpage Effect