<% title = request.querystring ("n") n = 0 %> <% ' Set up constants Const ForReading = 1 ' Input OutPut Mode Const Create = False strFileName = Server.MapPath(title & ".txt") ' Instantiate the FileSystemObject Set FSO = Server.CreateObject("Scripting.FileSystemObject") ' use Opentextfile Method to Open the text File Set TS = FSO.OpenTextFile(strFileName, ForReading, Create) If not TS.AtEndOfStream Then Do While not TS.AtendOfStream strLine = TS.ReadLine n = n + 1 if (n = 1) then ' title response.write "

" & strLine & "

" end if if (n = 2) then ' date response.write "
" & strLine & "

" end if if (n > 2) then ' text Response.Write strLine & VbCrLf end if loop End If ' close TextStreamObject and destroy local variables to relase memory TS.Close Set TS = Nothing Set FSO = Nothing %>
Torna a www.supercellulari.com