<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>GATTACA &#187; phpMailer</title>
	<atom:link href="http://gattaca.com.ar/tag/phpmailer/feed/" rel="self" type="application/rss+xml" />
	<link>http://gattaca.com.ar</link>
	<description>&#34;La vida es como una película de Hollywood, un bodrio que cuesta una fortuna.&#34; @Mic_y_Mouse</description>
	<lastBuildDate>Fri, 04 May 2012 00:59:12 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.2</generator>
		<item>
		<title>Clase PHP mailer: lo más cómodo para enviar e-mails en PHP</title>
		<link>http://gattaca.com.ar/2009/06/clase-php-mailer-lo-mas-comodo-para-enviar-e-mails-en-php/</link>
		<comments>http://gattaca.com.ar/2009/06/clase-php-mailer-lo-mas-comodo-para-enviar-e-mails-en-php/#comments</comments>
		<pubDate>Sat, 27 Jun 2009 19:55:30 +0000</pubDate>
		<dc:creator>C. Jaacks</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[phpMailer]]></category>

		<guid isPermaLink="false">http://gattaca.com.ar/?p=10</guid>
		<description><![CDATA[Siempre usé sencillamente el comando mail de PHP, ya que ni siquiera me pongo a hacer e-mails HTML desde mi programa de correo electrónico&#8230; menos me voy a poner a programar algo tan sofisticado (aunque no lo es tanto), ya que en general las notificaciones por mail no requieren mucho adorno. Aprendí en un una [...]]]></description>
			<content:encoded><![CDATA[<p>Siempre usé sencillamente el comando <strong>mail</strong> de PHP, ya que ni siquiera me pongo a hacer e-mails HTML desde mi programa de correo electrónico&#8230; menos me voy a poner a programar algo tan sofisticado (aunque no lo es tanto), ya que en general las notificaciones por mail no requieren mucho adorno.<br />
Aprendí en un una empresa para la que hago algunos trabajos a mandar mails <em>multipart</em>, o sea HTML y texto plano. Nada del otro mundo.<br />
La cosa se pone realmente molesta + peliaguda cuando querés hacer un file-attach (archivo adjunto). Programar eso no es imposible, pero roza lo imposible. Es tedioso con mayúsculas.<br />
En otro laburo que tuve que hacer, me pidieron que el sistema enviara tal file por e-mail. Como me rompí la cabeza entonces, cuanto tiempo perdí. Al final, decidí usar la clase <strong><a href="http://sourceforge.net/projects/phpmailer/files/phpmailer%20for%20php5_6/" title="phpMailer v5.0.2 para cuando escribo esto.">PHPmailer</a></strong>, que ya tenía por ahí y no le había dado mayor bola.  <span id="more-10"></span></p>
<p>Aquí les copio el ejemplo que viene en el <em>README</em> del .zip.</p>
<blockquote><p>
<code>&lt;?php<br />
require(&quot;class.phpmailer.php&quot;);</p>
<p>$mail = new PHPMailer();</p>
<p>$mail-&gt;IsSMTP();                                      // set mailer to use SMTP<br />
$mail-&gt;Host = &quot;smtp1.example.com;smtp2.example.com&quot;;  // specify main and backup server<br />
$mail-&gt;SMTPAuth = true;     // turn on SMTP authentication<br />
$mail-&gt;Username = &quot;jswan&quot;;  // SMTP username<br />
$mail-&gt;Password = &quot;secret&quot;; // SMTP password</p>
<p>$mail-&gt;From = &quot;from@example.com&quot;;<br />
$mail-&gt;FromName = &quot;Mailer&quot;;<br />
$mail-&gt;AddAddress(&quot;josh@example.net&quot;, &quot;Josh Adams&quot;);<br />
$mail-&gt;AddAddress(&quot;ellen@example.com&quot;);                  // name is optional<br />
$mail-&gt;AddReplyTo(&quot;info@example.com&quot;, &quot;Information&quot;);</p>
<p>$mail-&gt;WordWrap = 50;                                 // set word wrap to 50 characters<br />
$mail-&gt;AddAttachment(&quot;/var/tmp/file.tar.gz&quot;);         // add attachments<br />
$mail-&gt;AddAttachment(&quot;/tmp/image.jpg&quot;, &quot;new.jpg&quot;);    // optional name<br />
$mail-&gt;IsHTML(true);                                  // set email format to HTML</p>
<p>$mail-&gt;Subject = &quot;Here is the subject&quot;;<br />
$mail-&gt;Body    = &quot;This is the HTML message body &lt;b&gt;in bold!&lt;/b&gt;&quot;;<br />
$mail-&gt;AltBody = &quot;This is the body in plain text for non-HTML mail clients&quot;;</p>
<p>if(!$mail-&gt;Send())<br />
{<br />
   echo &quot;Message could not be sent. &lt;p&gt;&quot;;<br />
   echo &quot;Mailer Error: &quot; . $mail-&gt;ErrorInfo;<br />
   exit;<br />
}</p>
<p>echo &quot;Message has been sent&quot;;<br />
?&gt;<br />
</code>
</p></blockquote>
<p>Viene para PHP 4 o 5/6.<br />
Lo único que necesitás realmente es el <strong>class.phpmailer.php</strong> (67 Kb.), lo otro ni lo miré&#8230;  <img src='http://gattaca.com.ar/wp-includes/images/smilies/icon_lol.gif' alt=':lol:' class='wp-smiley' />  </p>
]]></content:encoded>
			<wfw:commentRss>http://gattaca.com.ar/2009/06/clase-php-mailer-lo-mas-comodo-para-enviar-e-mails-en-php/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
	</channel>
</rss>

