php8.0 버전 호환 코드 적용 및 PHP 끝 태그 삭제 일괄적용
This commit is contained in:
@ -1,17 +1,17 @@
|
||||
#PHPMailer Extras
|
||||
# PHPMailer Extras
|
||||
|
||||
These classes provide optional additional functions to PHPMailer.
|
||||
|
||||
These are not loaded by the PHPMailer autoloader, so in some cases you may need to `require` them yourself before using them.
|
||||
|
||||
##EasyPeasyICS
|
||||
## EasyPeasyICS
|
||||
|
||||
This class was originally written by Manuel Reinhard and provides a simple means of generating ICS/vCal files that are used in sending calendar events. PHPMailer does not use it directly, but you can use it to generate content appropriate for placing in the `Ical` property of PHPMailer. The PHPMailer project is now its official home as Manuel has given permission for that and is no longer maintaining it himself.
|
||||
|
||||
##htmlfilter
|
||||
## htmlfilter
|
||||
|
||||
This class by Konstantin Riabitsev and Jim Jagielski implements HTML filtering to remove potentially malicious tags, such as `<script>` or `onclick=` attributes that can result in XSS attacks. This is a simple filter and is not as comprehensive as [HTMLawed](http://www.bioinformatics.org/phplabware/internal_utilities/htmLawed/) or [HTMLPurifier](http://htmlpurifier.org), but it's easier to use and considerably better than nothing! PHPMailer does not use it directly, but you may want to apply it to user-supplied HTML before using it as a message body.
|
||||
|
||||
##NTLM_SASL_client
|
||||
## NTLM_SASL_client
|
||||
|
||||
This class by Manuel Lemos (bundled with permission) adds the ability to authenticate with Microsoft Windows mail servers that use NTLM-based authentication. It is used by PHPMailer if you send via SMTP and set the `AuthType` property to `NTLM`; you will also need to use the `Realm` and `Workstation` properties. The original source is [here](http://www.phpclasses.org/browse/file/7495.html).
|
||||
|
||||
@ -44,9 +44,9 @@ function tln_tagprint($tagname, $attary, $tagtype)
|
||||
$fulltag = '</' . $tagname . '>';
|
||||
} else {
|
||||
$fulltag = '<' . $tagname;
|
||||
if (is_array($attary) && sizeof($attary)) {
|
||||
if (is_array($attary) && count($attary)) {
|
||||
$atts = array();
|
||||
while (list($attname, $attvalue) = each($attary)) {
|
||||
foreach($attary as $attname => $attvalue) {
|
||||
array_push($atts, "$attname=$attvalue");
|
||||
}
|
||||
$fulltag .= ' ' . join(' ', $atts);
|
||||
@ -84,7 +84,7 @@ function tln_casenormalize(&$val)
|
||||
function tln_skipspace($body, $offset)
|
||||
{
|
||||
preg_match('/^(\s*)/s', substr($body, $offset), $matches);
|
||||
if (sizeof($matches[1])) {
|
||||
if (count($matches[1])) {
|
||||
$count = strlen($matches[1]);
|
||||
$offset += $count;
|
||||
}
|
||||
@ -439,9 +439,9 @@ function tln_getnxtag($body, $offset)
|
||||
function tln_deent(&$attvalue, $regex, $hex = false)
|
||||
{
|
||||
preg_match_all($regex, $attvalue, $matches);
|
||||
if (is_array($matches) && sizeof($matches[0]) > 0) {
|
||||
if (is_array($matches) && count($matches[0]) > 0) {
|
||||
$repl = array();
|
||||
for ($i = 0; $i < sizeof($matches[0]); $i++) {
|
||||
for ($i = 0; $i < count($matches[0]); $i++) {
|
||||
$numval = $matches[1][$i];
|
||||
if ($hex) {
|
||||
$numval = hexdec($numval);
|
||||
@ -520,7 +520,7 @@ function tln_fixatts(
|
||||
$trans_image_path,
|
||||
$block_external_images
|
||||
) {
|
||||
while (list($attname, $attvalue) = each($attary)) {
|
||||
foreach($attary as $attname => $attvalue) {
|
||||
/**
|
||||
* See if this attribute should be removed.
|
||||
*/
|
||||
@ -794,7 +794,7 @@ function tln_body2div($attary, $trans_image_path)
|
||||
$text = '#000000';
|
||||
$has_bgc_stl = $has_txt_stl = false;
|
||||
$styledef = '';
|
||||
if (is_array($attary) && sizeof($attary) > 0){
|
||||
if (is_array($attary) && count($attary) > 0){
|
||||
foreach ($attary as $attname=>$attvalue){
|
||||
$quotchar = substr($attvalue, 0, 1);
|
||||
$attvalue = str_replace($quotchar, "", $attvalue);
|
||||
@ -970,7 +970,7 @@ function tln_sanitize(
|
||||
/**
|
||||
* This is where we run other checks.
|
||||
*/
|
||||
if (is_array($attary) && sizeof($attary) > 0) {
|
||||
if (is_array($attary) && count($attary) > 0) {
|
||||
$attary = tln_fixatts(
|
||||
$tagname,
|
||||
$attary,
|
||||
|
||||
Reference in New Issue
Block a user