How to display local images placed on client machine in HTML webpages

后端 未结 3 918
Happy的楠姐
Happy的楠姐 2021-01-13 14:03

How to display local images placed on client machine in HTML webpages hosted on a webserver

I\'m having few images placed in C:/Images folder so path sh

3条回答
  •  佛祖请我去吃肉
    2021-01-13 14:22

    the src attribute is always in the context of the server that is serving the HTML content. I don't think there is a way around that.

    So in your example if the host is ip 1.1.1.1 and the client is ip 2.2.2.2

    then src would be pointing to 1.1.1.1\file://C:/images/1.jpg <--that's an example not a real protocol.

提交回复
热议问题