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 2 of 2
  1. #1
    New Coder
    Join Date
    Feb 2006
    Posts
    32
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Creating links to a network path

    Hi,

    Trying to make some links on my internal company page to some network resources.

    Kinda confusing question, but here goes.
    1) Should I put file:// in front of the network links?
    ex. file:////server1/folder/file.pdf

    It seems that IE6 automatically appends the file:// but if I urlencode the path it doesn't.
    URL Encoded Path being --> %2F%2Fserver1%2Ffolder%2Ffile%2Epdf

    And also should I use URLEncodedFormat for the links.. is it neccessary?

    Page will only be viewed on IE6 if that changes anything.

    Thanks for any help.

    RishiD

  • #2
    Senior Coder Arbitrator's Avatar
    Join Date
    Mar 2006
    Location
    Splendora, Texas, United States of America
    Posts
    3,274
    Thanks
    28
    Thanked 271 Times in 265 Posts
    I believe the correct protocol for local file retrieval is file:///C:\Documents and Settings\All Users\. At least on Windows anyway. I can't say exactly how it'll work when networked computers try to retrieve data though. Best bet is to try it, with an image for example, and find out.

    You shouldn't need to bother URL encoding the addresses. When the browser reads them the URLs will be either read the way they are or if the browser wants them encoded they will be encoded automatically. For example, this should work:

    <img src="file:///C:\Documents and Settings\All Users\">
    ... and should be converted automatically to something like ...
    <img src="file:///C:\Documents%20and%20Settings\All Users\">
    Last edited by Arbitrator; 04-24-2006 at 01:59 PM.
    For every complex problem, there is an answer that is clear, simple, and wrong.


  •  

    Posting Permissions

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