Relative link in Markdown images should not expand to local path when converted to HTML #146
Comments
Just to confirm, what do you think |
I am guessing he expects it should simply end up as:
As that is how people manually apply relative links. If a person clicks this link while he is on |
Is there any solution for this? |
@karas1999 How did you deal with this problem? |
I just quit Atom and went back to my old friend Sublime Text. It has much more plug-ins to improve markdown editing experience for me. But I do had found a way to solve this problem in Atom:
Sorry that I already deleted Atom so I'm not sure of this solution. If it's not working, you may need to do some more experiment to the code. You can even try Base64 encode all the images when exported to html. Then you don't need to bind the image with html file any more. |
@karas1999 Thank you. I try it later. |
Not only does it not work when the folder is moved, but some browsers (at least Firefox) do not allow absolute paths on the local filesystem anymore. So even locally, when the path is perfectly fine - all pictures are missing. |
Firefox allows absolute paths, but I've found I need to add |
When we put an image in Markdown using a relative path:
In current version (mine is 0.136.0, but there are probably no change to this in newer versions), the relative path is expanded to local absolute path to the image when converted to HTML:
Following the behavior when specifying a plain link, I think the relative path should not be expanded. In other words (as QuadPiece has commented):
Extra work is needed to relativize the links when we want to use the HTML on a webpage.
The text was updated successfully, but these errors were encountered: