Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 4 of 4
  1. #1
    Regular Coder
    Join Date
    Jul 2002
    Posts
    362
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Open a Directory and show on web page

    Im trying to open up a directory and show it on my web pages.
    Works with no problem in IE6 but cant get it to work in Netscape 7.0 and Netscape 4.77. The Directory sits on a Windows 2000 Info Server.

    Please advise:

    Code:
    <a href="file:////myinfoServer/myDirectory/">Open and view files in myDirectory</a>

  • #2
    Supreme Master coder! glenngv's Avatar
    Join Date
    Jun 2002
    Location
    Philippines
    Posts
    11,043
    Thanks
    0
    Thanked 251 Times in 247 Posts
    You are using the file protocol instead of the http protocol. This means that the myDirectory folder should be a network shared directory in the myinfoServer machine and the users have access to it. Is that really the setup?

    You need to add one more slash

    <a href="file://///myinfoServer/myDirectory/">Open and view files in myDirectory</a>

    Here's the breakdown of that 5 slashes:

    file://computeraddress///myinfoServer/myDirectory/

    computeraddress is usually empty but it is the ip address or host name.
    The blue part is the network path.

    That works in NS6+ and IE but not in NS4. NS4 wants a file not a directory unless it's not a network directory, it has to be a local directory.

    But why not setup the IIS in the server and create a virtual directory that points to that location and then enable directory browsing? This will not require sharing the folder. The link would then become:

    <a href="http://myinfoServer/dir/">Open and view files in myDirectory</a>

    The dir is the name you gave to the virtual directory, it can be the same with the actual physical directory.

  • #3
    Regular Coder
    Join Date
    Jul 2002
    Posts
    362
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Thanks it still doesnt work in Netscape.

    I was wondering if the problem is because I have a space in the Directory name?

    <a href="file://///myinfoServer/my Directory/DirectoryA/">Open and view files in myDirectory</a>

    where I try with and without the %20 part and it wont work either way with Netscape.

    <a href="file://///myinfoServer/my%20Directory/DirectoryA/">Open and view files in myDirectory</a>

  • #4
    Supreme Master coder! glenngv's Avatar
    Join Date
    Jun 2002
    Location
    Philippines
    Posts
    11,043
    Thanks
    0
    Thanked 251 Times in 247 Posts
    Can you try my second suggestion? That's the better solution even if you were able to make the first suggestion worked.


  •  

    Posting Permissions

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