All pastes #25923 Raw Edit

Untitled

public text v1 · immutable
#25923 ·published 2005-10-19 03:00 UTC
rendered paste body
<?php

/*
recorded for posterity...

function sendHTMLmail($fromid,$to,$subject,$message)
{
	$headers  = "From: $fromid\n";
	$headers .= "Reply-To: $fromid\n";
	$headers .= "MIME-Version: 1.0\n";
	$headers .= "Content-Type: text/html; charset=ISO-8859-1\n";
	$headers .= "Content-Transfer-Encoding: 8bit;\n\n";
	$headers .= stripslashes($message);
	$headers .= "\n";
	@mail("$to", "$subject", "", "$headers");
}
*/

function sendHTMLmail($fromid, $to, $subject, $message)
{
        $fromid = strtr($fromid, array("\r" => '', "\n" => ''));
	$headers = "From: $fromid\nReply-To: $fromid\nMIME-Version: 1.0\n"
	    . "Content-Type: text/html; charset=ISO-8859-1\n"
            . "Content-Transfer-Encoding: 8bit;\n\n";
	@mail($to, $subject, stripslashes($message), $headers);
}

?>