Reputation: 11
I´m working in a local project (offline) and need show a txt file outside of directory of html. How implement the relative path?
main-app
|
|-core-app
|
|-logs
| |-log-file.txt
|
|-plugin
|-plugin-core
|-www
|-index.html
The file is on logs folder, I need show it in index.html. I try to use src="../../../logs/log-file.txt" but don't work. An example of the code in html:
<object type="text/plain" data="../../../logs/log-file.txt"></object>
Upvotes: 0
Views: 2337
Reputation: 29
Just change the .txt file to a .html file, and add styling... It works just fine, just add a linkto it in index.html.
Upvotes: -2
Reputation: 516
relative to index.html I think that it should be : data="../../logs/log-file.txt". One less directory shift.
Upvotes: 3