473,569 Members | 2,466 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Email html page with images

Das
Hi,

I'm trying to email html page & that page also contains the images. I can
do that when we send html page from ms outlook. But I want to attach page c#
code & send the mail through smtp mail.

Thanx in advance..

Regards,

das
Nov 18 '05 #1
5 3086
Place the images on a web server and then...

<img src="http://www.whateverdom ainyouuse.com/some_directory/some_image.jpg"
border="0">

--

Derek Davis
dd******@gmail. com

"Das" <Da*@discussion s.microsoft.com > wrote in message
news:18******** *************** ***********@mic rosoft.com...
Hi,

I'm trying to email html page & that page also contains the images. I can
do that when we send html page from ms outlook. But I want to attach page
c#
code & send the mail through smtp mail.

Thanx in advance..

Regards,

das

Nov 18 '05 #2
While that certainly is an option, it's a problem, since you will have
to host those images. It would be easier to just embed the images in the
email itself.

This article shows how to do that. It will have to be tweaked for
however he is sending the email, but it should give the basic idea.

http://www.codeproject.com/csharp/EmbedEmailImages.asp

Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard. caspershouse.co m

"carion1" <dd******@gmail .com> wrote in message
news:%2******** ********@TK2MSF TNGP10.phx.gbl. ..
Place the images on a web server and then...

<img
src="http://www.whateverdom ainyouuse.com/some_directory/some_image.jpg"
border="0">

--

Derek Davis
dd******@gmail. com

"Das" <Da*@discussion s.microsoft.com > wrote in message
news:18******** *************** ***********@mic rosoft.com...
Hi,

I'm trying to email html page & that page also contains the images. I can
do that when we send html page from ms outlook. But I want to attach page
c#
code & send the mail through smtp mail.

Thanx in advance..

Regards,

das


Nov 18 '05 #3
Mail server admins around the world love this! Embedding images in the
message is an option but IMO it is a bad one.

--

Derek Davis
dd******@gmail. com

"Nicholas Paldino [.NET/C# MVP]" <mv*@spam.guard .caspershouse.c om> wrote in
message news:%2******** ********@TK2MSF TNGP10.phx.gbl. ..
While that certainly is an option, it's a problem, since you will have
to host those images. It would be easier to just embed the images in the
email itself.

This article shows how to do that. It will have to be tweaked for
however he is sending the email, but it should give the basic idea.

http://www.codeproject.com/csharp/EmbedEmailImages.asp

Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard. caspershouse.co m

"carion1" <dd******@gmail .com> wrote in message
news:%2******** ********@TK2MSF TNGP10.phx.gbl. ..
Place the images on a web server and then...

<img
src="http://www.whateverdom ainyouuse.com/some_directory/some_image.jpg"
border="0">

--

Derek Davis
dd******@gmail. com

"Das" <Da*@discussion s.microsoft.com > wrote in message
news:18******** *************** ***********@mic rosoft.com...
Hi,

I'm trying to email html page & that page also contains the images. I
can
do that when we send html page from ms outlook. But I want to attach
page c#
code & send the mail through smtp mail.

Thanx in advance..

Regards,

das



Nov 18 '05 #4
Why?

The idea is to send a self contained piece of information to the client
which is not dependent on anything outside of the email.

It's actually better than storing the images on your server, since now,
downloadable content in emails is pretty much nixed by any respectable email
client (in order to prevent spam emails from verifying email addresses).

Also, from the mail admin's point of view, it's an extra piece of
information flying through the system. I don't see why they should care
that much (if they are on the receiving end).

--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard. caspershouse.co m

"carion1" <dd******@gmail .com> wrote in message
news:O%******** *******@TK2MSFT NGP10.phx.gbl.. .
Mail server admins around the world love this! Embedding images in the
message is an option but IMO it is a bad one.

--

Derek Davis
dd******@gmail. com

"Nicholas Paldino [.NET/C# MVP]" <mv*@spam.guard .caspershouse.c om> wrote
in message news:%2******** ********@TK2MSF TNGP10.phx.gbl. ..
While that certainly is an option, it's a problem, since you will have
to host those images. It would be easier to just embed the images in the
email itself.

This article shows how to do that. It will have to be tweaked for
however he is sending the email, but it should give the basic idea.

http://www.codeproject.com/csharp/EmbedEmailImages.asp

Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard. caspershouse.co m

"carion1" <dd******@gmail .com> wrote in message
news:%2******** ********@TK2MSF TNGP10.phx.gbl. ..
Place the images on a web server and then...

<img
src="http://www.whateverdom ainyouuse.com/some_directory/some_image.jpg"
border="0">

--

Derek Davis
dd******@gmail. com

"Das" <Da*@discussion s.microsoft.com > wrote in message
news:18******** *************** ***********@mic rosoft.com...
Hi,

I'm trying to email html page & that page also contains the images. I
can
do that when we send html page from ms outlook. But I want to attach
page c#
code & send the mail through smtp mail.

Thanx in advance..

Regards,

das



Nov 18 '05 #5
That 20k message is now much bigger. Mail servers are bloated enough. I
completely understand the advantage of this to the programmer (spammer).
Yes, most mail clients will block the external content but they also allow
you to view it if you want. This is just my opinion based on my situation
(exchange is part of my responsibility) .

--

Derek Davis
dd******@gmail. com

"Nicholas Paldino [.NET/C# MVP]" <mv*@spam.guard .caspershouse.c om> wrote in
message news:%2******** ********@TK2MSF TNGP12.phx.gbl. ..
Why?

The idea is to send a self contained piece of information to the client
which is not dependent on anything outside of the email.

It's actually better than storing the images on your server, since now,
downloadable content in emails is pretty much nixed by any respectable
email client (in order to prevent spam emails from verifying email
addresses).

Also, from the mail admin's point of view, it's an extra piece of
information flying through the system. I don't see why they should care
that much (if they are on the receiving end).

--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard. caspershouse.co m

"carion1" <dd******@gmail .com> wrote in message
news:O%******** *******@TK2MSFT NGP10.phx.gbl.. .
Mail server admins around the world love this! Embedding images in the
message is an option but IMO it is a bad one.

--

Derek Davis
dd******@gmail. com

"Nicholas Paldino [.NET/C# MVP]" <mv*@spam.guard .caspershouse.c om> wrote
in message news:%2******** ********@TK2MSF TNGP10.phx.gbl. ..
While that certainly is an option, it's a problem, since you will
have to host those images. It would be easier to just embed the images
in the email itself.

This article shows how to do that. It will have to be tweaked for
however he is sending the email, but it should give the basic idea.

http://www.codeproject.com/csharp/EmbedEmailImages.asp

Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
- mv*@spam.guard. caspershouse.co m

"carion1" <dd******@gmail .com> wrote in message
news:%2******** ********@TK2MSF TNGP10.phx.gbl. ..
Place the images on a web server and then...

<img
src="http://www.whateverdom ainyouuse.com/some_directory/some_image.jpg"
border="0">

--

Derek Davis
dd******@gmail. com

"Das" <Da*@discussion s.microsoft.com > wrote in message
news:18******** *************** ***********@mic rosoft.com...
> Hi,
>
> I'm trying to email html page & that page also contains the images. I
> can
> do that when we send html page from ms outlook. But I want to attach
> page c#
> code & send the mail through smtp mail.
>
> Thanx in advance..
>
> Regards,
>
> das



Nov 18 '05 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
4456
by: Chris Nafziger | last post by:
In my code to send email from VBScript, I use standard CDOSYS code similar to the following: With oMsg Set .Configuration = oCon .To = """Admin"" <admin@mycompany.com>" .From = """Joe Admin"" <jadmin@mycompany.com>" .Subject = "Hey You!" .TextBody = "Service(s) have failed!" .Send
7
7122
by: TLMM | last post by:
I have an HTML page which is a newsletter. I want to be able to add it to an email message so I can email it to people. I want it to be in the body of the email, not sent as an attachment. There is a .htm page, several images, and a .css page. I need all of these to be embedded for the page to work correctly. I can put the styles from the...
7
3041
by: cj | last post by:
If anyone can help me with this, I would reeeeally appreciate it: I am trying to send an email that contains a 'webpage" within it. I have seen this done a million times, like in the emails I get from NetFlix and Jetblue, but I'm not able to figure this out on my own. When I simply take my html code and copy it into the body of an email,...
0
8732
by: shaolinman829 | last post by:
My collegue and I are at the point of pulling our hair out. I'm currently writting a little piece of Java code to send an email confirmation page that sends both html and text. Not a problem. In my html, I'm using an image with which I reference through a cid i1. My problem is, in the email I send, I can only get the images to show up if I do: ...
0
255
by: sri_san | last post by:
Hello, I am using the system.net.mail class to send out email in HTML format. I have a few images in the HTML page. In order to have the images display without referencing the server, attaching the images to the email and calling the image like - '<img src='email2.jpg'works fine to me (atleast in an internal network). I keep reading in the...
1
1660
by: =?Utf-8?B?RGF2aWQ=?= | last post by:
Hi all, I need to generate an HTML email message that is sent to internal customers. Rather than build the message as a string in my code, I have developed a web page I want to send as the body of the message. I'm using the httpWebRequest and httpWebResponse objects retrieve the contents of the page, but the images and stylesheets both use...
2
4685
by: Aneesh Pulukkul[MCSD.Net] | last post by:
Hi, I have a HTML page and associated images. I need to send the HTML as email -the email should also display the images at respective places. So am sending the content of HTML file as MailMessage.Body and adding all the referred images using MailMessage.Attachments.Add(). The images referred using <IMG SRC="Logo.png" /are displaying...
7
3598
by: imtmub | last post by:
I have a page, Head tag Contains many Scripts and style sheet for Menu and Page. This code working fine and displaying menus and page as i wanted. Check this page for reference. http://www.marco.com.cn/web-content/marco_re10.html -------------------------------------------------------------- <head> <!-- InstanceBeginEditable...
1
1785
by: runway27 | last post by:
<?php $headers = "Content-type: text/html; charset=iso-8859-1"; $to="myemailaddress"; $subject="Email Newsletter"; $message = '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <title>Email Newsletter</title>
0
7703
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main...
0
7926
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. ...
0
8132
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that...
1
7678
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For...
0
7982
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
0
6286
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then...
0
5222
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert...
1
2116
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
1
1226
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.