有人知道如何在markdown显示本地图像吗?我不想为此设置网络服务器。
我尝试以下markdown,但它不起作用:

有人知道如何在markdown显示本地图像吗?我不想为此设置网络服务器。
我尝试以下markdown,但它不起作用:

当前回答
你可能会发现下面的语法类似于markdown中的引用链接,特别是当你有一个文本有许多相同的图像显示时:
![optional text description of the image][number]
[number]: URL
例如:
![][1]
![This is an optional description][2]
[1]: /home/jerzy/ComputerScience/Parole/Screenshot_2020-10-13_11-53-29.png
[2]: /home/jerzy/ComputerScience/Parole/Screenshot_2020-10-13_11-53-30.png
其他回答
根据你的工具-你也可以注入HTML markdown。
<img src="./img/Isolated.png">
这假设你的文件夹结构是:
├── img
└── Isolated.jpg
├── README.md
在Jupyter笔记本Markdown,您可以使用
<img src="RelPathofFolder/File" style="width:800px;height:300px;">
只需从markdown文件中添加相对图像文件路由

最好的解决方案是提供一个相对于md文档所在文件夹的路径。
浏览器在尝试解析本地文件的绝对路径时可能遇到了麻烦。这可以通过通过web服务器访问文件来解决,但即使在这种情况下,图像路径也必须是正确的。
在文档的同一级别设置一个文件夹,包含所有图像,这是最干净和最安全的解决方案。 它将加载到GitHub,本地,本地web服务器。
images_folder/img.jpg < works
/images_folder/img.jpg < this will work on webserver's only (please read the note!)
使用绝对路径,图像只能通过如下url访问:http://hostname.doesntmatter/image_folder/img.jpg
我怀疑这条路不对。正如user7412219所提到的,ubuntu和windows处理路径不同。试着把图片和你的笔记本放在同一个文件夹中,并使用:

在windows上,桌面应该在:C:\Users\jzhang\Desktop