4 Replies Latest reply on Dec 3, 2006 3:51 AM by SiuLinda

    How to Access File in DswMedia folder

    SiuLinda Level 1
      Dear all,

      Do anyone know the way to access the DswMedia folder as relative path when in shockwave?
      I have tried "\DswMedia" or even instructed by Macromedia web site "File://", both doesn't work...
      Are there any method to know the path of individual computer on where the DswMedia folder is?
      Thanks in advance!

      Linda
        • 1. Re: How to Access File in DswMedia folder
          duckets Level 1

          How about checking "_movie.path" and searching that string for 'dswmedia' ?

          - Ben
          • 2. Re: How to Access File in DswMedia folder
            SiuLinda Level 1
            Thanks again Ben.
            Well, I think _movie.path can't work to search 'dswmedia' folder cos when the dcr and html are put into the server, it will just prompt the _movie.path as "www.mydomain.com", rather than the user's harddisk.
            Anyway, thank you.
            • 3. How to Access File in DswMedia folder
              duckets Level 1
              The dswmedia folder is specifically for use when the shockwave movie itself is running from the user's hard disk.

              It has no effect on movies running from the web. Movies running from the web can only access files within their own web domain (or other web domains, with a security pop up box). They cannot access files on the user's HD even if there's a dswmedia folder somwhere.

              Shockwave movies have restrictions placed on what they can do, to avoid the possibility of maliciously written dcr's causing damage to users' data.

              When running from the web: Shockwave can read external files within the same domain as the dcr, or files from another web domain, if a security pop-up box is confirmed by the user. It cannot access files on the user's local machine, with the exception of 'setpref' and 'getpref' files.

              When running locally without a dswmedia folder: Shockwave cannot read external files, or discover local filenames (for example, the movie path value is empty).

              When running locally within a dswmedia folder: Shockwave can read external files that are within the dswmedia folder, and can ascertain the moviepath.

              The dswmedia folder is therefore to allow the 'simulation' of how shockwave runs on the web, bypassing the extra security restrictions normally placed on shockwave movies when run off the local HD.

              So the only kind of shockwave movie that can read files off the user's HD (with the exception of pref files) is one which itself is running locally, and is within a dswmedia folder on the user's HD.

              Sorry for the bad news!
              Hope this clears things up,

              - Ben

              • 4. Re: How to Access File in DswMedia folder
                SiuLinda Level 1
                Thanks anyway.
                I searched that Shockfiler Xtra is able to transfer and find the location of dswmedia folder, I have tried to email them but still get no feedback.
                I am still looking forward for their reply on dswmedia folder enquiry.