Backslash issue [message #1413822] |
Fri, 29 August 2014 09:58  |
Eclipse User |
|
|
|
I am using the Kepler Release of Eclipse with PDT on Windows using XAMPP. I would like to launch the project in Firefox. To do this, I set up a run external tool configuration as:
Location: C:\Program Files (x86)\Mozilla Firefox\firefox.exe
Arguments: 127.0.0.1/workspace2${container_path}/${resource_name}
or 127.0.0.1/workspace2${resource_path}
where 127.0.0.1/workspace2 is my workspace location on Apache
When I run this, Firefox launches but the URL contains backslashes and the @Server not found' message is received. If I change the arguments to 127.0.0.1${resource_path} then resource_path correctly gives forward slashes, but this does not work for me because the path is wrong. It seems that the '/' in the prefix causes the resource file to return with backslashes.
When I look at the documentation for eclipse at http://help.eclipse.org/luna/index.jsp?topic=%2Forg.eclipse.platform.doc.user%2Fconcepts%2Fconcepts-exttools.htm the example shows that calling ${resource_path} should give forward slashes (as might be expected for a web resource).
I have tried everything that I can think of but I always get the backslashes when I include the workspace path and can't find a way to fix this. Is this a bug in Eclipse? Any ideas or suggestions will be appreciated.
|
|
|
|
|
Re: Backslash issue [message #1415183 is a reply to message #1414623] |
Tue, 02 September 2014 05:09  |
Eclipse User |
|
|
|
Thank you for taking the time to provide such a detailed answer, this is much appreciated.
I solved my problem by creating a virtual host (called vhost) and then configured the 'Run As' with
Arguments: vhost${resource_path}
This works with Firefox, IE and Chrome and I now am able to launch the html or php directly to any browser for testing.
Note: if I put 'http://' before vhost then the resource path uses backslashes again and stops working.
Once again, thank you. I have little doubt that your assistance will save others, who also encounter this problem, a lot of time in the future.
|
|
|
Powered by
FUDForum. Page generated in 0.19016 seconds