firebase-storage

What is the purpose behind getDownloadURL of Firebase Storage

南笙酒味 提交于 2020-02-15 09:16:10
问题 Per these docs, I understand once we have the firebase path in storage, we can get the download url by calling getDownloadUrl() on this path's ref . My question is all the docs suggest to get the download url first then download file data based on these image, but can we persist this download url in our realtime db for the file, so we don't have to call getDownloadUrl() each time? Current file upload and download workflow -> Upload: 1. upload file to storage in specific path. 2. store path in

Uploading image (ACTION_IMAGE_CAPTURE) to Firebase storage [duplicate]

随声附和 提交于 2020-02-07 08:41:21
问题 This question already has answers here : What is a NullPointerException, and how do I fix it? (12 answers) Closed 3 years ago . EDIT: The discussion on this issue has been carried to another question: Image capture with camera & upload to Firebase (Uri in onActivityResult() is null) PLEASE check it out! I did some manipulations (following the android documentation) but still getting same problem. So here I'm trying to do a simple task of capturing an image with camera and uploading it to my

Uploading image (ACTION_IMAGE_CAPTURE) to Firebase storage [duplicate]

夙愿已清 提交于 2020-02-07 08:39:33
问题 This question already has answers here : What is a NullPointerException, and how do I fix it? (12 answers) Closed 3 years ago . EDIT: The discussion on this issue has been carried to another question: Image capture with camera & upload to Firebase (Uri in onActivityResult() is null) PLEASE check it out! I did some manipulations (following the android documentation) but still getting same problem. So here I'm trying to do a simple task of capturing an image with camera and uploading it to my

Flutter & Firebase - using firebase_storage along with firebase_auth

安稳与你 提交于 2020-02-06 16:55:03
问题 Working with the firebase packages: https://pub.dartlang.org/packages/firebase_auth https://pub.dartlang.org/packages/firebase_storage I can sign into firebase using firebase_auth, and everything works great there, but when I use the firebase_storage package to upload a file I get access denied and I have to go into firebase and set the permissions to: service firebase.storage { match /b/{bucket}/o { match /{allPaths=**} { allow read, write;//: if request.auth != null; } } } This is not ideal

Flutter & Firebase - using firebase_storage along with firebase_auth

假如想象 提交于 2020-02-06 16:54:25
问题 Working with the firebase packages: https://pub.dartlang.org/packages/firebase_auth https://pub.dartlang.org/packages/firebase_storage I can sign into firebase using firebase_auth, and everything works great there, but when I use the firebase_storage package to upload a file I get access denied and I have to go into firebase and set the permissions to: service firebase.storage { match /b/{bucket}/o { match /{allPaths=**} { allow read, write;//: if request.auth != null; } } } This is not ideal

Why can't Facebook share pick up my Firebase storage image file?

那年仲夏 提交于 2020-02-04 02:57:48
问题 I have the following button: <a class="btn btn-social btn-facebook" href="https://www.facebook.com/dialog/feed?app_id=1732jjjjjjj &redirect_uri={{statusUrl}} &link=https://sitename.com/{{statusUrl}} &name={{isTitle}} &picture=https://firebasestorage.googleapis.com/v0/b/rrrr.appspot.com/o/eWebcontent%2Fc0638f6c65d2aa5c81f9ef820531eda2?alt=media&token=93c157e6-05ec-4efe-8ca5-86942cfac742 &caption=www.sitename.com &author=Author &description={{statusDesc}}. &properties={text:’value1′,key2:

How can I setup Firebase Storage rules to check parameters in Firebase Database?

僤鯓⒐⒋嵵緔 提交于 2020-02-02 16:16:48
问题 I have the following data structures in Firebase Firebase Database House/(id)/Viewers/(UID)/{ startdate = “Dec 1, 2019” endData = “Dec 8, 2019” } Firebase Storage House/(id)/SensitiveImages/sensitiveImage.png I want to write a rule in Firebase storage that only allows access to the SensitiveImages folder if the users UID is inside of the list of Viewers and the current time is between the startDate and endDate. However, there is no way to access this information from inside the Firebase

Get Download URL from Firebase Storage in Flutter

自作多情 提交于 2020-01-31 05:18:06
问题 I'm currently exploring Flutter, I found there is an official Firebase Storage plugin in Flutter firebase_storage I have storage reference like this one: final StorageReference ref = FirebaseStorage.instance.ref().child("default.png"); But there is no method to get download URL from that StorageReference. 回答1: If the above solution doesn't work, try this: Future<String> uploadImage(var imageFile ) async { StorageReference ref = storage.ref().child("/photo.jpg"); StorageUploadTask uploadTask =

I am trying to get download url from firebase but it gives me some another link like “com.google.android.gms.tasks.zzu@b9761c8” [duplicate]

↘锁芯ラ 提交于 2020-01-30 11:14:58
问题 This question already has an answer here : Can't get download url from Firebase Storge in Android [duplicate] (1 answer) Closed 2 years ago . I am trying to get download url from firebase but it gives me some another link like "com.google.android.gms.tasks.zzu@b9761c8" 回答1: You need to add listeners when retrieving the url. Please read the documentations taskSnapshot.getDownloadUrl().addOnSuccessListener(new OnSuccessListener<Uri>() { @Override public void onSuccess(Uri uri) { // Got the uri

I am trying to get download url from firebase but it gives me some another link like “com.google.android.gms.tasks.zzu@b9761c8” [duplicate]

∥☆過路亽.° 提交于 2020-01-30 11:10:46
问题 This question already has an answer here : Can't get download url from Firebase Storge in Android [duplicate] (1 answer) Closed 2 years ago . I am trying to get download url from firebase but it gives me some another link like "com.google.android.gms.tasks.zzu@b9761c8" 回答1: You need to add listeners when retrieving the url. Please read the documentations taskSnapshot.getDownloadUrl().addOnSuccessListener(new OnSuccessListener<Uri>() { @Override public void onSuccess(Uri uri) { // Got the uri