+ Post New Thread
Results 1 to 3 of 3
Coding Thread, ASP Classic FileSystemObject in Coding and Web Development; Can anyone confirm or deny that FileSystemObject methods need local paths not URLs ? I am trying to create a ...
  1. #1

    TechMonkey's Avatar
    Join Date
    Dec 2005
    Location
    South East
    Posts
    3,286
    Thank Post
    225
    Thanked 405 Times in 302 Posts
    Rep Power
    162

    ASP Classic FileSystemObject

    Can anyone confirm or deny that FileSystemObject methods need local paths not URLs ? I am trying to create a txt file on a hosted system and they are saying that you can only use urls for security as is standard security.

    Is this true? So there is no way to write a txt file to an IIS webserver?

  2. #2

    Join Date
    Aug 2005
    Location
    London
    Posts
    3,155
    Thank Post
    114
    Thanked 527 Times in 450 Posts
    Blog Entries
    2
    Rep Power
    123
    I suspect what they're telling you is that they're not going to let you write files like this. ASP certainly supports it:
    Code:
    set oFso=server.CreateObject("scripting.filesystemobject")
    sRoot=server.MapPath(".")
    set oFile=osfo.createtextfile(sRoot & "\" & test.txt)
    oFile.writeline "Testing"
    oFile.close
    (server.mappath just works out "where am I?" - it will return something like c:\inetpub\wwwroot\mysite\myfolder)

    The problem is that if you can write "good stuff" then a hacker can probably write "bad stuff"

    What are you wanting to write? Could it be put in a database instead?

  3. Thanks to srochford from:

    TechMonkey (26th August 2009)

  4. #3

    TechMonkey's Avatar
    Join Date
    Dec 2005
    Location
    South East
    Posts
    3,286
    Thank Post
    225
    Thanked 405 Times in 302 Posts
    Rep Power
    162
    Ta. Yeah sorry I know it does work, I have it running on a server here. It was mainly if they are right that it is standard not to allow it & then wondering what otehr people did if they are on hosted servers.

    What I am doing is an emergency message system. If the school loses power or connection a page will be presented and I just wanted a text file to store time, date, message and reason that would be written by an admin page. Looks like I will have to stick with just uploading the text file.

SHARE:
+ Post New Thread

Similar Threads

  1. FileSystemObject Folder why permission denied
    By NetworkGeezer in forum Coding
    Replies: 16
    Last Post: 2nd September 2011, 05:10 PM
  2. [Video] Classic Eric and Ernie
    By mattx in forum Jokes/Interweb Things
    Replies: 6
    Last Post: 21st April 2009, 11:56 AM
  3. VBScript and 'Scripting.filesystemobject'
    By placky in forum Scripts
    Replies: 3
    Last Post: 1st April 2008, 04:49 PM
  4. Classic Phrases
    By button_ripple in forum General Chat
    Replies: 93
    Last Post: 16th January 2008, 09:28 PM

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •