|
Re: Computing help URLs [message #474769 is a reply to message #474763] |
Wed, 12 November 2008 00:38 |
Chris Goldthorpe Messages: 815 Registered: July 2009 |
Senior Member |
|
|
The help server will only serve documents that are located in plugins.
Partly this is for security reasons, we don't want users to be able to
access our entire disks through the web server.
If the server sees an address like
http://127.0.0.1:3477/help/topic/org.eclipse.jdt.doc.user/co ncepts/concept-java-search.htm
it will interpret it as a file in the plugin org.eclipse.jdt.doc.user.
When you use ".." it does not cause you to navigate relative to the file
structure on disc, rather it affects the url so if from that page you
opened "../../foo.html" it would try to open
http://127.0.0.1:3477/help/topic/foo.html
which would not be found.
Amit Mookerjee wrote:
> Hi,
> I have made an eclipse plugin and facing the following issues in
> computing the URL:
>
> 1. URL for documents relative paths : I have a help plugin that appears
> to work when the document I refer to is located below the plug-in
> directory. So when I compute the 'href' argument in
> PlatformUI.getWorkbench().getHelpSystem().displayHelpResourc e(href);
> in the following way:
>
> href = "/org.eclipse.rtsc.xdctools.help/" + "cdoc/" +
> elemName.replace('.', '/') + "/package.html";
>
> help shows the document located in the 'cdoc' sub-directory located in
> the plugin directory.
>
> However, if the documents are kept at a level higher, the document does
> not showup.
>
> In other words computing 'href' in the following way
>
> href = "/org.eclipse.rtsc.xdctools.help/" + "../docs/cdoc/" +
> elemName.replace('.', '/') + "/package.html";
>
> does not work. How do I compute 'href' when my docs are located above
> the plugin directory?
>
> 2. URL for documents in zipped files: If I have the sub-directory 'cdoc'
> mentioned in part 1 zipped up, then the following computation of 'href'
> does not work
>
> href = "/org.eclipse.rtsc.xdctools.help/" + "docs.zip!/cdoc/" +
> elemName.replace('.', '/') + "/package.html";
>
> What would be the right way to compute the URL for documents residing
> within a zipped file?
>
>
|
|
|
Re: Computing help URLs [message #621806 is a reply to message #474763] |
Wed, 12 November 2008 00:38 |
Chris Goldthorpe Messages: 815 Registered: July 2009 |
Senior Member |
|
|
The help server will only serve documents that are located in plugins.
Partly this is for security reasons, we don't want users to be able to
access our entire disks through the web server.
If the server sees an address like
http://127.0.0.1:3477/help/topic/org.eclipse.jdt.doc.user/co ncepts/concept-java-search.htm
it will interpret it as a file in the plugin org.eclipse.jdt.doc.user.
When you use ".." it does not cause you to navigate relative to the file
structure on disc, rather it affects the url so if from that page you
opened "../../foo.html" it would try to open
http://127.0.0.1:3477/help/topic/foo.html
which would not be found.
Amit Mookerjee wrote:
> Hi,
> I have made an eclipse plugin and facing the following issues in
> computing the URL:
>
> 1. URL for documents relative paths : I have a help plugin that appears
> to work when the document I refer to is located below the plug-in
> directory. So when I compute the 'href' argument in
> PlatformUI.getWorkbench().getHelpSystem().displayHelpResourc e(href);
> in the following way:
>
> href = "/org.eclipse.rtsc.xdctools.help/" + "cdoc/" +
> elemName.replace('.', '/') + "/package.html";
>
> help shows the document located in the 'cdoc' sub-directory located in
> the plugin directory.
>
> However, if the documents are kept at a level higher, the document does
> not showup.
>
> In other words computing 'href' in the following way
>
> href = "/org.eclipse.rtsc.xdctools.help/" + "../docs/cdoc/" +
> elemName.replace('.', '/') + "/package.html";
>
> does not work. How do I compute 'href' when my docs are located above
> the plugin directory?
>
> 2. URL for documents in zipped files: If I have the sub-directory 'cdoc'
> mentioned in part 1 zipped up, then the following computation of 'href'
> does not work
>
> href = "/org.eclipse.rtsc.xdctools.help/" + "docs.zip!/cdoc/" +
> elemName.replace('.', '/') + "/package.html";
>
> What would be the right way to compute the URL for documents residing
> within a zipped file?
>
>
|
|
|
Powered by
FUDForum. Page generated in 0.04424 seconds