Jump to content

E-mail - while


web_master

Recommended Posts

Hi,

how can I implement while query in email:

 

 

$address  = "[email protected]";
$subject    = "Novi registrovani korisnik";
$message  = "KORISNIK:  <strong>".$request_user['tt_reg_name']." ".$request_user['tt_reg_fname']."</strong><br>".
		"E-MAIL:  <strong>".$request_user['tt_reg_email']."</strong><br>".
		"GRAD:  <strong>".$request_user['tt_reg_city']."</strong><br>".
		"TELEFON:  <strong>".$request_user['tt_reg_phone']."</strong><br>".
		"IZABRANI PROIZVOD:  <strong>".$request_product['tt_reg_product_choice']."</strong><br>".
		"IZABRANE GRUPE PROIZVODA:<br>".

"this down is a problem between stars, to write in mail all query"
*********************************************************************************
		while ($request_user_choice = mysql_fetch_array($query)) {
		print "<strong>".$request_user_choice['tt_product_group_sr']."</strong><br>";
		}
*********************************************************************************

$headers = "From: [email protected]".
    		"Reply-To: [email protected]" . "\r\n" .
    		'X-Mailer: PHP/' . phpversion() . "\r\n" .
		'MIME-Version: 1.0' . "\r\n".
		'Content-type: text/html; charset=iso-utf-8' . "\r\n";

mail($address, $subject, $message, $headers);

 

 

thnxs?

Link to comment
https://forums.phpfreaks.com/topic/55376-e-mail-while/
Share on other sites

Man you are sending many mails why dont you use teh group_mail class from here

Class aviliable from here

http://zigmoyd.sourceforge.net/man/mail.php#group_mail

Installlation and Instruction on

http://zigmoyd.sourceforge.net/man/index.php

Its really too easy and much better than mail.

 

no, I dont want to send a many mails...

 

I have one while query for example:

 

while ($request = mysql_fetch_array($query)) {

$request_user_choice['tt_product_group_sr']."< br >";

}

 

this will look like this after echo:

 

something 1

something 2

something 3 ...

 

in while  query, I want to write this something1, something2 something 3.... in e-mail body...

Link to comment
https://forums.phpfreaks.com/topic/55376-e-mail-while/#findComment-273722
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.