Community
Participate
Working Groups
For local URLs we're using thing like '/images/folder.png' in our css files and our script references in our HTML files are also using '/requirejs/require.js'. We need to stop doing this as it prevents us and others from moving the code around and in particular of the web server root. All local URLs should NOT start with '/' and instead should use relative syntax. e.g. '../images/folder.png'
it should be rather ../../orion/images/folder.png
(In reply to comment #1) > it should be rather ../../orion/images/folder.png I am curious here. Noticed that Simon refactored them , like , e.g. require.toUrl("images/file.gif") Should we just assume that .toUrl knows how to convert it ?
To be honest I'd prefer it if there were NO image URLs in our JavaScript files. Instead it would be better to use a class and a css file that knows about the image. We need to keep things like "style" and "icons" out of our JavaScript and instead reference by class and do the styling in CSS -- just common sense.
(In reply to comment #3) > To be honest I'd prefer it if there were NO image URLs in our JavaScript files. We are working toward this in bug 349237.
I've corrected fileClientPlugin.html. It used window.location.origin to make the path relative, but window.location.origin exists only on Chrome. fileClientPlugin.html coulnd't install on FF and IE. I've changed it to smart use of window.location.host.
Good catch. Thanks Gosia.
I've added a protocol check to the logic to make sure we don't try to make http and https resources relative
We're generally in good shape here on the client now. I'll leave this open and do more checks for RC2.
When running the server with a different context path (/cc), the git-clone page doesn't work. It tries to call /gitapi/ URLs rather than /cc/gitapi/. Also, I noticed that GitRemoteHandlerV1 and GitCommitHandlerV1 are doing path math to get a task URL: > private URI createTaskLocation(URI baseLocation, String taskId) throws URISyntaxException { > return new URI(baseLocation.getScheme(), baseLocation.getAuthority(), "/task/id/" + taskId, null, null); //$NON-NLS-1$ > } That looks like it will fail too.
Marking fixed retroactively based on what we've done for 0.3. We still have work here for our Git Client and Server but I'll open a different bug for 0.4 to track that work.