我正在使用CakePHP 2.3.0和CakeEmail。cakephp 2.3.0 CakeEmail
我可以毫無問題地發送電子郵件。 爲了去除 那總是附加到發送的電子郵件 我期待找到並刪除
<p>This email was sent using the <a href="http://cakephp.org">CakePHP Framework</a></p>
,但它不是默認模板 希望這能成爲其中的一部分「這封電子郵件是使用CakePHP框架生成」完成 非常感謝!
CakePHP中2.3.2 /app/View/Emails/html/default.ctp的內容是這樣的
<?php
/**
*
* PHP 5
*
* CakePHP(tm) : Rapid Development Framework (http://cakephp.org)
* Copyright (c) Cake Software Foundation, Inc. (http://cakefoundation.org)
*
* Licensed under The MIT License
* For full copyright and license information, please see the LICENSE.txt
* Redistributions of files must retain the above copyright notice.
*
* @copyright Copyright (c) Cake Software Foundation, Inc. (http://cakefoundation.org)
* @link http://cakephp.org CakePHP(tm) Project
* @package app.View.Emails.html
* @since CakePHP(tm) v 0.10.0.1076
* @license MIT License (http://www.opensource.org/licenses/mit-license.php)
*/
?>
<?php
$content = explode("\n", $content);
foreach ($content as $line):
echo '<p> ' . $line . "</p>\n";
endforeach;
?>
而且/app/View/Emails/html/default.ctp的內容看起來是這樣的
<?php
/**
*
* PHP 5
*
* CakePHP(tm) : Rapid Development Framework (http://cakephp.org)
* Copyright (c) Cake Software Foundation, Inc. (http://cakefoundation.org)
*
* Licensed under The MIT License
* For full copyright and license information, please see the LICENSE.txt
* Redistributions of files must retain the above copyright notice.
*
* @copyright Copyright (c) Cake Software Foundation, Inc. (http://cakefoundation.org)
* @link http://cakephp.org CakePHP(tm) Project
* @package app.View.Emails.text
* @since CakePHP(tm) v 0.10.0.1076
* @license MIT License (http://www.opensource.org/licenses/mit-license.php)
*/
?>
<?php echo $content; ?>
所以我該怎麼辦去除的代碼 希望這個看不見的線可以做到這一點 太謝謝你了!