Jump to content

Need some help with txt logs


Guest Stunner

Recommended Posts

You Can use FSO!! Exp:dim Fso,TxtFileSet Fso=Server.Createobject("Scripting.FileSystemObject")Set TxtFile=Fso.OpenTxtFile(ServerMapPath("SomeTxtFile.txt"),2,true) ' SomeTxtFile.txt Means: The txt file Path Which you want to write.' 2 Means: open txt file by write only' true means: if the txt file is not exists then create itTxtFile.WriteLine (Request.Form("FormData"))TxtFile.CloseSet TxtFile=NothingSet Fso=Nothing

Well, i am trying to make a form and when u submit it, it saves to a txt file that i can view later. Can someone help me with this?

Link to comment
Share on other sites

Well, i am trying to make a form and when u submit it, it saves to a txt file that i can view later. Can someone help me with this?

You'll probably need server-side scripting to accomplish that. Something like PHP, ASP, Pearl, etc. You can also e-mail yourself the text, which will also require server-side scripting.
Link to comment
Share on other sites

You Can use FSO!! Exp:dim Fso,TxtFileSet Fso=Server.Createobject("Scripting.FileSystemObject")Set TxtFile=Fso.OpenTxtFile(ServerMapPath("SomeTxtFile.txt"),2,true)  '  SomeTxtFile.txt Means: The txt file Path Which you want to write.' 2 Means: open txt file by write only' true means: if the txt file is not exists then create itTxtFile.WriteLine (Request.Form("FormData"))TxtFile.CloseSet TxtFile=NothingSet Fso=Nothing

This is ASP (VBScript). It is a very simple solution. PHP probably has a very similar approach.
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...