[英]How to get absolute path of a document and file from Google Drive Using Java Drive Rest V2 API?
[英]How to get full path to file on Google Drive?
SO 10311092中發布了許多方法,其中一些方法已被棄用。 但是,截至2018年10月,似乎仍然可以使用。ctf0的答案非常簡單。
這是來自@ https://productforums.google.com/forum/#!topic/drive/yU_yF9SI_z0/discussion的方法
1-上傳您的圖片
2-右鍵單擊並選擇“獲取共享鏈接”
3-復制鏈接應該看起來像
https://drive.google.com/open?id=xxxxxxx
4改變開放? 到uc? 並像這樣使用
<img src="https://drive.google.com/uc?id=xxxxx">
- 建議您在從網絡上引用任何內容時刪除http:或https :,以避免您的服務器出現任何問題。
或者,您也可以嘗試Google的方法 :通過webViewLink
屬性中的URL為用戶提供對文件的直接訪問。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.