We use shared folders and we refer these shared folders like this <cfcontent file = "\\1.1.1.1\someSharedFolder\Documents1.pdf"> where 1.1.1.1 is an ip addr and folder structure in windows is like this
X:/*Shared*/someSharedFolder/Documents1.pdf and someSharedFolder is a shared folder. We have D,E,F,X so many shared drives on this machine. Notice that in the code, I have not referenced *Shared*. Ajas. On 4/24/08, Peyton Todd <[EMAIL PROTECTED]> wrote: > > (Reading through what I wrote, there were a few other errors, so I send > this version to clear up possible confusion. Sorry.) > > My web site needs to load PDFs which are located in a different directory > (in fact, on a different disk drive) than the one on which the site's web > pages reside. In developing this website by working as localhost on my own > desktop PC at home, the following code works flawlessly: > > <cfcontent file = 'D:/Styles/553/55303.pdf'> > > The web page containing the above line of code, and everything else in the > site, is on a subdirectory of C:/Inetpub/wwwroot/. And in real life the > parameter 'D:/Styles/553/55303.pdf' is a #variable# which can evaluate to > that path among others; I'm hard-coding it here to simplify the example. > > My problem is that this must work on a network where the target is in a > virtual directory on a different box. Since that virtual directory presents > itself to us humans as drive J, the value of the file attribute in the above > <cfcontent> tag presumably becomes 'J:/553/55303.pdf'. But when I plug > 'J:/553/55303.pdf' into the above tag, both Firefox(FF) and Internet > Explorer(IE) complain that the file does not exist. > > A different approach is suggested by the fact that Windows Explorer (a.k.a > 'My Computer') shows the 'real(?), or underlying(?) location corresponding > to virtual drive J to be "Styles on 'dsm=svr1-acr'". The Help desk at > Leapfrog (the company which built my client's network) suggested that I use > '//dsm-svr1-acr/553/55303.pdf' instead of 'J:/553/55303.pdf'. But when I try > that, FF says it 'can't establish a connection to the server at > dsm-svr1-acr'; and IE says 'Page cannot be displayed'. > > The third method I tried was to use <cflocation> istead of <cfcontent>, as > below: > > <cflocation url="J:/553/55303.pdf">. > > I would assume <cflocation> should be equivalent to the <cfcontent> tag in > this situation since, based on the Livedocs, the difference between the two > seems to be only that <cfcontent> provides extra capabilities such as > specifying the MIME type, loading from a variable instead of a file, and > deleting the file after its contents are loaded to the page; and none of > those capabilities are needed here. Is there any a priori reason why I > should prefer one of these tags to the other here? > > In any case, when I try the code with <cflocation> as above, sometimes the > PDF is loaded exactly as desired, and sometimes it is not. So far I have so > far not been able to figure out what determines success or failure. When it > does NOT work, FF sometimes interprets the letter J as a protocol, and > reports that it 'doesn't know how to open this address because the protocol > (J) isn't associated with any program'. At other times it simply loads a > blank page with no error message (based on my notes, this seems to depend on > whether the value of the url attribute was substituted vs. hard-coded but > I'm not sure of this). As to IE, when the <cflocation> method does not work, > I get a javascript message saying 'Error: Member not found' (I neglected to > mention that the page containing the <cfcontent> or <cflocation> tag is > actually loaded to a child window via the javascript code: > > win=window.open(showpdf,'Style','width=800,height=500,resizable=yes') > > where showpdf evaluates to the url of the page containing the <cfcontent> > or <cflocation> tag, with the path to the file as part of its query string. > > Can anyone shed light on what's happening here, and what I should be doing > to make this work? > > > > > > > ------------------------------------------------------------- > Annual Sponsor FigLeaf Software - http://www.figleaf.com > > To unsubscribe from this list, manage your profile @ > http://www.acfug.org?fa=login.edituserform > > For more info, see http://www.acfug.org/mailinglists > Archive @ http://www.mail-archive.com/discussion%40acfug.org/ > List hosted by http://www.fusionlink.com > ------------------------------------------------------------- > > > > -- <Ajas Mohammed /> http://ajashadi.blogspot.com No matter what, find a way. Because thats what winners do. You can't improve what you don't measure. Quality is never an accident; it is always the result of high intention, sincere effort, intelligent direction and skillful execution; it represents the wise choice of many alternatives. "Live as if you were to die tomorrow. Learn as if you were to live forever." ------------------------------------------------------------- Annual Sponsor FigLeaf Software - http://www.figleaf.com To unsubscribe from this list, manage your profile @ http://www.acfug.org?fa=login.edituserform For more info, see http://www.acfug.org/mailinglists Archive @ http://www.mail-archive.com/discussion%40acfug.org/ List hosted by http://www.fusionlink.com -------------------------------------------------------------
