Link to home
Start Free TrialLog in
Avatar of rgb192
rgb192Flag for United States of America

asked on

imbeded images

phpmailer() displayed this image by default in gmail without prompting user to 'show images'


$mail->AddEmbeddedImage("photoofme.jpg", "picofme", "photoofme.jpg");
$mail->Body = 'Hi! Here is a picture of me: <img src="cid:picofme">';


but I emailed a gmail and noticed today I had to click 'show images' to see the image

maybe I sent the email differently
or is gmail as of today blocking imbeded images
Avatar of sivagnanam chandrakanth
sivagnanam chandrakanth
Flag of India image

Google will always block embedded images based on the data it has.

If have given always allow for a domain, then it wont ask again.
ASKER CERTIFIED SOLUTION
Avatar of Loganathan Natarajan
Loganathan Natarajan
Flag of India image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Gmail has a link that allows the client to display images.  It looks something like this, attached.  IIRC you can put background colors into HTML emails and those will work correctly, as will some CSS styling.  But the CSS styling is inconsistent among email reader programs.
display-images.png
Avatar of rgb192

ASKER

I do not want user interaction to show the images 'clicking display images in gmail client'


from logudotcom

We'll only show images in messages that are authenticated


is this asking me to spf domain key dns the email
I do not want user interaction to show the images 'clicking display images in gmail client'
You can't control or circumvent this.  It is under Google's control and the client's control.  Other email reader programs may operate differently, but GMail requires the client to authorize the display of images.  The client can authorize the display permanently on a per-sender basis.
Avatar of rgb192

ASKER

when I use phpmailer
$mail->AddEmbeddedImage("photoofme.jpg", "picofme", "photoofme.jpg");
$mail->Body = 'Hi! Here is a picture of me: <img src="cid:picofme">';

with gmail  as the sender


then the recipient can see the images without clicking on 'display images'


maybe if I use spf dns domain key for my non gmail mail
Avatar of rgb192

ASKER

best reasoning.
thanks