上下載鏈接據developer.android.com
當用戶點擊一個網站
http://developer.android.com/tools/publishing/publishing_overview.html#publishing-website
When users browse to the download link from their Android-powered
devices, the file is downloaded and Android system automatically
starts installing it on the device. However, the installation process
will start automatically only if the user has configured their
Settings to allow the installation of apps from unknown sources.
這似乎是可以自動啓動安裝過程無需用戶如何自動啓動的Android APK安裝過程相互作用。我已選中該框以允許來源不明的應用,但我仍然需要手動觸發安裝過程。我看到這似乎暗示什麼是官方網站上說的相反的同一主題的很多帖子:
How to install APK automatically when the file download is complete (hosted on private)
how to automatically install an apk
How to automatically launch the Android installer after downloading the apk?
別人似乎表明,唯一的出路有安裝過程中自動出現的情況是通過已安裝的應用程序:
Android: install .apk programmatically
,我有要求是,用戶只需要點擊一個單一鏈路上的專用部署網站和應用程序的安裝會自動無需做別的用戶觸發。
目前,當我點擊鏈接在我的網站上部署,所做的只是下載apk文件,我需要手動啓動安裝過程。
沒有這些問題的答案真的打動了我什麼,我需要,在官方網站上的說明將是完美的,因爲它不需要任何東西,除了我無法得到它的工作,安裝其他自定義應用程序安裝原始應用程序在嘗試安裝時也會遇到同樣的問題。
我們還部署了內部測試目的iOS應用程序,我們正在做的方式是通過清單文件的鏈接從頁面
http://help.apple.com/iosdeployment-apps/mac/1.1/#app43ad871e
樣品鏈接: <a href="itms-services://?action=download-manifest&url=http://example.com/
manifest.plist">Install App</a>
是否有一些額外的步驟,我必須做的,以獲得官方安卓網站上的說明工作?也許有辦法讓下載鏈接的行爲像iOS清單文件鏈接?或者還有其他方法可以達到我的要求?
謝謝。
您描述您的瀏覽器如何工作的方式也是我的測試設備中的瀏覽器(默認瀏覽器(chrome))如何工作,我必須通過通知手動觸發安裝。但是這會使android官方網站的說法無效('安裝將自動啓動')。有沒有辦法實現默認瀏覽器的默認操作? – George
@George:「但是這使官方Android網站所說的內容無效(安裝將自動啓動)」 - 文檔已過時。股票AOSP瀏覽器應用程序自從Android 2.2 IIRC以來沒有進行自動安裝,並且在任何情況下都可能不是用戶的默認瀏覽器。 「沒有辦法實現默認瀏覽器的默認操作?」 - 有成千上萬的Android設備和少數「默認瀏覽器」應用程序。儘管SDK文檔中有一條過時的語句可能暗示,但它們都不需要自動安裝APK。 – CommonsWare