c# – E-mail Embedded file (by way of “cid:” hyperlink) engaged on android telephones however not on iPhone / iPad?

0
1
c# – E-mail Embedded file (by way of “cid:” hyperlink) engaged on android telephones however not on iPhone / iPad?


I am attempting to make a backend-service that sends out e-mail with an “Add to Apple Pockets” Button. This works, the e-mail is there with textual content and a “Add to Apple Pockets” button rendered. There’s additionally an attachment within the e-mail “pass_mitterlehner.pkpass” that I can click on and it’ll present the dialog so as to add an move.

Now right here is my drawback whats NOT engaged on an iPhone or iPad however works on an Android Telephone:
Android Telephone (gmail): Once I click on the “Add to Apple Pockets” button it appropriately downloads the hooked up “move.pkass”.
iPhone or iPad (default “mail” app): Once I click on the “Add to Apple Pockets” button it solely opens the picture of the button however not the cid hyperlink to the attachment. If I provide the cid hyperlink with out the button it simply does nothing clicking it.

The code seems like this for including the 2 attachments (button picture and .pkass file)(C# and fluentmail):

        .Connect(new FluentEmail.Core.Fashions.Attachment
        {
            Information = System.IO.File.OpenRead(aWalletImgPath + aWalletImgName),
            ContentType = "picture/png",
            Filename = aWalletImgName,
            IsInline = true,
            ContentId = "addToAppleWallet"
        })
         .Connect(new FluentEmail.Core.Fashions.Attachment
         {
             Information = File.OpenRead(appleWalletLink),
             ContentType = "utility/vnd.apple.pkpass",
             Filename = "pass_mitterlehner.pkpass",
             IsInline = true,
             ContentId = "pass_mitterlehner.pkpass",
         })

Then after I make the e-mail with the button + hyperlink and hyperlink solely:

            
                Add to Apple Wallet 
           
            
                    Obtain Apple Pockets Go
            

I don’t perceive why the linking to the attachment (by way of “https://stackoverflow.com/questions/79579059/cid:pass_mitterlehner.pkpass”) works on Android Telephones however not on iPhone / iPad.

EDIT1: I’ve made one other remark. Its appears to work solely with gmail. Within the code I take advantage of “href=”https://stackoverflow.com/questions/79579059/cid:pass_mitterlehner.pkpass”” as proven, nevertheless after I click on the hyperlink within the e-mail I get redirected to “https://mail.google.com/mail/?ui=2&ik=3ba88a04b5&attid=0.3&th=196436bbbbc7fe4f&view=att&disp=emb&zw”. Might or not it’s that Gmail sees the wished linking by way of “cid” and robotically generates a short lived obtain hyperlink for the hooked up file?

LEAVE A REPLY

Please enter your comment!
Please enter your name here