$mail_body = htmlspecialchars($user."\n".$quest."\n".$mail);
$adminEmail = $kernel->pub_modul_properties_get('email'); if ($adminEmail['isset'] && $kernel->pub_is_valid_email($adminEmail['value'])) {//не пустой и валидный email админа $mail_body = htmlspecialchars($user."\n".$quest."\n".$mail); $kernel->pub_mail(array($adminEmail['value']), array($adminEmail['value']), $adminEmail['value'], 'admin', 'Новый вопрос', $mail_body, false); }
$mail_body = htmlspecialchars($user."\r\n".$quest."\r\n".$mail);
<? $user = 'user'; $quest = 'quest'; $mail = 'mail'; $mail_body = htmlspecialchars($user."\r\n".$quest."\r\n".$mail); echo($mail_body); ?>
user<br />quest<br />mail
$user = htmlspecialchars($user); $quest = htmlspecialchars($quest); $mail = htmlspecialchars($mail); $mail_body = $user."<br />".$quest."<br />".$mail;
<?php $user = 'user'; $quest = 'quest'; $mail = 'mail'; $mail_body = str_replace(array($separator,"\r","\n"), array('',"","<br />"), htmlspecialchars($user."\r\n".$quest."\r\n".$mail)); echo($mail_body); ?>
$mail_body = str_replace(array($separator,"\r","\n"), array('','</p>',"<p>"), htmlspecialchars("\n".$user."\r\n".$quest."\r\n".$mail."\r"));