SitePoint Sponsor

User Tag List

Results 1 to 7 of 7

Thread: File listing

  1. #1
    SitePoint Member
    Join Date
    Jun 2003
    Location
    New Zealand
    Posts
    5
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Smile File listing

    Trying to use javascript on web page to read network folder and put listing of files onto web page somehow, is this possible. Would generate links to files so user can click on link to download file. Any help appreciated, even if it is say it cannot be done. From 144Soft here in New Zealand

  2. #2
    SitePoint Addict
    Join Date
    May 2000
    Posts
    313
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Sorry JavaScript is not able to read from files or write to them. You will have to use a Server Side language such as PHP or Perl.

  3. #3
    SitePoint Member
    Join Date
    Jun 2003
    Location
    New Zealand
    Posts
    5
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Thanks

  4. #4
    ☆★☆★ silver trophy vgarcia's Avatar
    Join Date
    Jan 2002
    Location
    in transition
    Posts
    21,235
    Mentioned
    1 Post(s)
    Tagged
    1 Thread(s)
    Quote Originally Posted by requestcode
    Sorry JavaScript is not able to read from files or write to them. You will have to use a Server Side language such as PHP or Perl.
    There's always server-side javascript with ASP . However, I highly doubt he would want to do this.

  5. #5
    SitePoint Enthusiast
    Join Date
    Jun 2003
    Posts
    30
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Maybe I don't understand what you want to do, but:
    if it's just one folder, can't you do as follows (but I don't know if it's recommended securitywise)?

    You put all your downloadable files in one folder which has no index file, have a link point to that folder, you have your link list (server-side directory index).

    If the files are .htm you can change them to .txt and tell the user to change it back after dowload.

    Of course you don't control the appearance of the directory index page.

  6. #6
    SitePoint Addict
    Join Date
    May 2000
    Posts
    313
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I don't hear much about Server Side Javascript anymore. Thats why I don't mention it. ASP is also an excellent choice although I have not used it before. I know a couple of years ago JS Server Side was discussed a lot in other forums.

  7. #7
    SitePoint Member
    Join Date
    Jun 2003
    Location
    New Zealand
    Posts
    5
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Thanks pietro, I want to list drawing files relating to a drawing number, they are on a seperate server and could be .dwg or .tif files, and various numbers of these. (0 to 450 files) Server side ASP seem to be the only option and its difficult because our IT Dept have locked down the access from IIS 5.0 for security reasons. They dont want the files on the web server either. We have a desktop solution at present, the web solution may be too hard.


Bookmarks

Posting Permissions

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