This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 256652 - Root relative path is not working
Summary: Root relative path is not working
Status: RESOLVED WORKSFORME
Alias: None
Product: web
Classification: Unclassified
Component: HTML Editor (show other bugs)
Version: 8.1
Hardware: PC Windows 10 x64
: P3 normal (vote)
Assignee: Milutin Kristofic
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-11-17 20:16 UTC by wishmaster35
Modified: 2016-07-15 14:34 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description wishmaster35 2015-11-17 20:16:44 UTC
I include a css:
<link href="./css/common.css" rel="stylesheet">

A path kind of './css/common.css' works only if the html placed in a root of Site Root or Sources folder.
If the html in a src/html/ or public_html/html/ folder then NetBeans can't load JS or CSS by this url.

A path kind of '/css/common.css' does not work at all.


I also want to offer the feature.
When html placed in Sources folder, would be great if NetBeans could look for css, js and other files in Sources and Site Root folders (for prompts and autocompletion).
Because now I'm forced to store css(compiled less) and bower libs in the Site Root and Sources folder.
Comment 1 Milutin Kristofic 2016-07-15 14:34:57 UTC
I recreated your scenario.

I have following  directory tree

public_html/html/css/common.css
public_html/html/test.html

and in test.html there is link
<link href="./css/common.css" rel="stylesheet" type="text/css"/>

If I click on ./css/common.css Netbeans open common.css


Maybe you want ../css/common.css or something like that if css in in public_html.