On Sep 5, 11:17 am, Benjamin Smedberg <[EMAIL PROTECTED]> wrote:
> James Newell wrote:
> > Thanks BDS,
>
> > I am using the first method as it makes more sense in the particular
> > application i am using. It seems to work and if I load "resource://
> > ufcontent/" into the browser, then I get a directory listing of the
> > the "root" resource directory as expected. However if I enter
> > "resource://ufcontent/test.html" I get a not found error. If I enter,
> > "resource://ufcontent/content/test.html" where content is the
> > directory within my application that test.html exists it works...
>
> > Why does the resource work for "resource://ufcontent/" but not
> > "resource://ufcontent/test.html"?
>
> Probably because the substitution URI doesn't have a trailing slash: you
> want to setSubstitution to "file:///some/path/" not "file:///some/path"
> because when you resolve "test.html" against "file:///some/path" you end up
> with "file:///some/test.html" which is not what you intended.
>
> --BDS

Cheers!

_______________________________________________
dev-tech-network mailing list
[email protected]
https://lists.mozilla.org/listinfo/dev-tech-network

Reply via email to