我想知道是否可以在公共网站上访问/显示存储在谷歌驱动器中的图像等文件。
当前回答
你可以直接从Drive & Gmail来做。方法如下:
1.上传图片到谷歌驱动器并设置查看权限(可以是公共或任何人w/ link)
去Gmail>撰写。选择附件图标旁边的+。 选择驱动器图标(三角形) 导航到您的图像和右键复制图像url 粘贴到网页浏览器或嵌入网页根据需要。
其他回答
以下是来自@ https://productforums.google.com/forum/#!主题/传动/ yU_yF9SI_z0 /讨论
1-上传你的图片
2-右击并选择“获取共享链接”
3-复制链接应该看起来像
https://drive.google.com/open?id=xxxxxxx
4-换开场?加州大学吗?然后像这样使用它
<img src="https://drive.google.com/uc?id=xxxxx">
从谷歌驱动器帮助页面:
To host a webpage with Drive: Open Drive at drive.google.com and select a file. Click the Share button at the top of the page. Click Advanced in the bottom right corner of the sharing box. Click Change.... Choose On - Public on the web and click Save. Before closing the sharing box, copy the document ID from the URL in the field below "Link to share". The document ID is a string of uppercase and lowercase letters and numbers between slashes in the URL. Share the URL that looks like "www.googledrive.com/host/[doc id] where [doc id] is replaced by the document ID you copied in step 6. Anyone can now view your webpage.
更新:正如所宣布的,谷歌在2016年8月弃用了此功能。这是谷歌的最后一次更新。
是的,这是可能的。如果你把文件放在公用文件夹中,你可以通过这个URL获取文件夹中的任何文件:
https://googledrive.com/host/<folderID>/<filename>
对于图像,在谷歌查看器中打开图像。即。
方法1
https://docs.google.com/file/d/0Bz7qe_olclTwWDNJRDRmb1pJamM/edit
然后查看源>找到单词“texmex-thumb”,旁边会有链接。
Vetea,如果你从图片URL中获取链接,它不工作,但如果你从“直接链接”字段中获取它,它应该工作。我在多个场合使用并测试过它。