-
Notifications
You must be signed in to change notification settings - Fork 907
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cannot share image using Facebook, WhatsApp or shareVia() function. #774
Comments
hello, did you manage to share file ? |
No, I haven't tried. Let me try it now. |
Ok so I just tried to share a pdf file, except for Mail, every other sharing function failed. However, for twitter, the app got opened and only the message was shown (this was happening even when I was sharing a picture). |
For your reference, following is my code: |
UP UP |
Did you find a solution for this? Sharing an image on fb / whatsapp? |
Hi,
i never try to share image on whatsapp, i just want to share pdf file to
whatsappa, but it should be same as image. i have try few way just no luck
and the whatsapp only show message only, no attachment.
i have post another issue after try for few day, below is my new post
#856
…On Wed, Jul 26, 2017 at 2:04 AM, Hesesses ***@***.***> wrote:
Did you find a solution for this? Sharing an image on fb / whatsapp?
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#774 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AYgy5onFNF2NzDvKrc_W9mWoCbSo425Xks5sRi4egaJpZM4L-c03>
.
|
Hello @replysam2009 !! I've got this same error. In my case, this is happened because the file To solve this, I did these things below:
<provider android:authorities="${applicationId}.sharing.provider" android:exported="false" android:grantUriPermissions="true" android:name="nl.xservices.plugins.FileProvider">
<meta-data android:name="android.support.FILE_PROVIDER_PATHS" android:resource="@xml/sharing_paths" />
</provider> ExtraWhether you need share a file with a custom extension (e.g I hope that steps above help you 😄 |
Thanks @mfdeveloper your solution works great!!! |
@Juliocbr We're welcome! I'm so glad that solution works to you 😃 |
I couldn't share media on Android (on iOS sharing worked fine). I constantly got the bug for the Android xml parser. After adding the code above in AndroidManifest.xml, this worked fine. thanks @mfdeveloper !!
|
Thanks to @mfdeveloper, I've implemented the same within config.xml: <platform name="android">
...
<config-file parent="/manifest/application" target="AndroidManifest.xml">
<provider android:authorities="${applicationId}.sharing.provider" android:exported="false" android:grantUriPermissions="true" android:name="nl.xservices.plugins.FileProvider">
<meta-data android:name="android.support.FILE_PROVIDER_PATHS" android:resource="@xml/sharing_paths" />
</provider>
</config-file>
...
</platform> |
Hey @ab-kily and @RenewedPlains, these exatly same Did you try remove and add this plugin again? I need add these tags manually, because my project is an Android Native, with an Activity that loads a cordova app. |
Thanks @mfdeveloper. |
@mfdeveloper: sir in my case files are already exist in the place that you have mentioned but still error i got Sharing failed please try again error only from whatsapp.can you tell me sir any another solution |
Hy @kapilSoni101 !! Did you try the solutions of @ab-kily to put the |
@mfdeveloper - yes sir it's already added |
Hi, I am using Social Sharing plugin in one of my Ionic2 projects. Earlier everything was working fine but from past 3 days I am not being able to share anything using different share functions (except for shareViaMail()). Whenever I try to share anything it says: "Attempt to invoke virtual method 'android.content.res.XmlResourceParserandroid.content.pm.ProviderInfo.loadXmlMetaData(android.content.pm.PackageManager, java.lang.String)' on a null object reference."
This happens only when I try to share image. If I share only message and Url, it works fine but if I try to share any image (by giving its url as a string), it throws an error.
Is there anything you can help me with?
The text was updated successfully, but these errors were encountered: