Go Back  HTML Forums - Free Webmaster Forums and Help Forums > WEBSITE DEVELOPMENT > Server Side Programming > PHP Programming
User Name:
Password:
 

Reply
Thread Tools   Display Modes
  View First Unread
 
Old 03-25-2008, 07:36 PM
  #1
Horus_Kol
Mod of the Underlay
 
Horus_Kol's Avatar
 
Join Date: Jun 2002
Location: At a desk, hooked up and ready to rock
Posts: 16,213
iTrader: (0)
Horus_Kol is a jewel in the roughHorus_Kol is a jewel in the roughHorus_Kol is a jewel in the roughHorus_Kol is a jewel in the rough
PHP Mailer - HTML images being blocked by Outlook

I'm using PHP Mailer to send an HTML email with embedded images - but my Outlook client is blocking them no matter what security settings I make...

PHP Code:
$mail->AddEmbeddedImage('/images/logo_lg.gif''logo_lg''logo_lg.gif');
$mail->AddEmbeddedImage('/images/bg_logo.gif''bg_logo''bg_logo.gif'); 
HTML Code:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
	"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html>

<head>

	<meta http-equiv="Content-type" content="text/html; charset=UTF-8">

</head>

<body>
	<div id="fix_width">
	
		<div id="header">
			
			<div id="left_header">
			
				<div id="main_logo"><a href="/"><img src="cid:logo_lg" alt="LOGO" title="LOGO" width="389" height="82"/></a></div>
				
			</div>
			
			<div id="center_header">
			
				<div id="breadcrumbs">
					&nbsp;	
				</div>
		
			</div>
			
		</div>
	
	</div>
	
	
	<div id="content" class="fullcontent">
	
		<div class="heading"><div class="label">Do you see images?</span></div></div>
		
		<div class="content_box">
			Please, let me know!!!
		</div>
		
		<div class="heading"><div class="label">Section Heading</span></div></div>
		
		<div class="content_box">
			Content
		</div>
		
		<div class="end_marker"></div>
	
	</div>
	
	<div id="footer"></div>
</body>
Horus_Kol is offline   Add to del.icio.us Add to del.icio.us    Can you digg it?Can you digg it? Reply With Quote
Old 03-26-2008, 06:35 AM
  #2
Vege
Novice
 
Vege's Avatar
 
Join Date: Sep 2004
Location: Finland
Posts: 2,706
iTrader: (0)
Vege will become famous soon enoughVege will become famous soon enough
Are you normally seeing images in outlook? Atleast in thunderbird you have to specifically turn the images on.
And if you can see images in other messages, you can prolly just check the mail source to see how they are build.
__________________

i hate you
Vege is offline   Add to del.icio.us Add to del.icio.us    Can you digg it?Can you digg it? Reply With Quote
Old 03-26-2008, 06:37 PM
  #3
Horus_Kol
Mod of the Underlay
 
Horus_Kol's Avatar
 
Join Date: Jun 2002
Location: At a desk, hooked up and ready to rock
Posts: 16,213
iTrader: (0)
Horus_Kol is a jewel in the roughHorus_Kol is a jewel in the roughHorus_Kol is a jewel in the roughHorus_Kol is a jewel in the rough
yes, images are normally displayed... the problem isn't just that they are blocked - I am completely unable to unblock them....

i think the problem is due to my embedding them into the email and using the "cid:" source instead of linking to the image on the webserver...
Horus_Kol is offline   Add to del.icio.us Add to del.icio.us    Can you digg it?Can you digg it? Reply With Quote
Old 03-26-2008, 09:00 PM
  #4
Horus_Kol
Mod of the Underlay
 
Horus_Kol's Avatar
 
Join Date: Jun 2002
Location: At a desk, hooked up and ready to rock
Posts: 16,213
iTrader: (0)
Horus_Kol is a jewel in the roughHorus_Kol is a jewel in the roughHorus_Kol is a jewel in the roughHorus_Kol is a jewel in the rough
found it:

PHP Code:
$mail->AddEmbeddedImage('/images/logo_lg.gif''logo_lg''logo_lg.gif');
if (
$mail->IsError()) {
  echo 
$mail->ErrorInfo;

gave me the information that I needed - the file could not be located...

I was using a URL relative to the server document root - but I need a full server path... whoops

what Outlook was really trying to say was "there is no image" - instead of "blocked, and you can't unblock it"
Horus_Kol is offline   Add to del.icio.us Add to del.icio.us    Can you digg it?Can you digg it? Reply With Quote
Reply
« Previous Thread | Next Thread »


 
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
  
 
 
 



 
  POSTING RULES
 
 
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Thread Tools
Display Modes

Forum Jump

 

All times are GMT -5. The time now is 08:08 AM.

   

Mascot team created by Drawshop.com

Powered by vBulletin® Version 3.6.7
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.

Server Monitoring by ENIACmonitor 0.01
HTMLforums.com © Big Resources, Inc. Web Design by BoxedArt.com
vRewrite 1.5 beta SEOed URLs completed by Tech Help Forum and Chalo Na.