php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #8113 there is a "!" and a linebreak in any mail that i send in text mode
Submitted: 2000-12-05 05:09 UTC Modified: 2000-12-05 06:34 UTC
From: christian at buyclever dot de Assigned:
Status: Closed Package: Mail related
PHP Version: 4.0.3pl1 OS: linux
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: christian at buyclever dot de
New email:
PHP Version: OS:

 

 [2000-12-05 05:09 UTC] christian at buyclever dot de
--with-apcs --with-mcrypt --with-pdflib --with-mysql --enable-ftp --with-zlib

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2000-12-05 05:52 UTC] sniper@php.net
Please add a short example script into this report which
can be used to reproduce this.

--Jani
 [2000-12-05 05:59 UTC] christian at buyclever dot de
function create_order_productlist($productid, $number, $price, $description, $option_name1, $option1, $option_name2, $option2, $currency) {
	$file_pl = fopen(bc_TEMPLATES_TXT . "order_product_list.txt", "r");
	
	/* format auslesen */
	while (!feof($file_pl)) {
		$row = trim(fgets($file_pl, 1024)) . "\r";
		if (strstr($row, "[%option1_name%]")) {
			if (is_set($option_name1)) $message .= $row;
		} else {
			$message .= $row;
		}
	}
	
	/* produkt einsetzen */
	$message = str_replace("[%productid%]", $productid, $message);
	$message = str_replace("[%number%]", $number, $message);
	$message = str_replace("[%price%]", parse($price), $message);
	$message = str_replace("[%currency%]", $currency, $message);
	$message = str_replace("[%description%]", $description, $message);
	$message = str_replace("[%option1_name%]", $option_name1, $message);
	$message = str_replace("[%option1%]", $option1, $message);
	$message = str_replace("[%option2_name%]", $option_name2, $message);
	$message = str_replace("[%option2%]", $option2, $message);
	$message = str_replace("[%number_price%]", parse($number * $price), $message);
	
	fclose($file_pl);
	
	return $message;
}

$ordermail = create_order_mail($order_productlist, $sender, $userid, $orderid, $firstname, $lastname, $address, $zipcode, $city, $country, $SETTINGS_sendcosts, $total, $SETTINGS_currency, $SETTINGS_takecosts);

mail($email, "Subject", "$ordermail", "From: $sender\nContent-Type: text");
 [2000-12-05 06:34 UTC] sniper@php.net
'Content-Type: text' should be 'Content-Type: text/plain'

--Jani
 
PHP Copyright © 2001-2021 The PHP Group
All rights reserved.
Last updated: Sun May 16 09:01:23 2021 UTC