summaryrefslogtreecommitdiff
path: root/Postman/PostmanLogFields.php
diff options
context:
space:
mode:
authoryehudah <yehudah@b8457f37-d9ea-0310-8a92-e5e31aec5664>2020-06-20 21:39:39 +0000
committeryehudah <yehudah@b8457f37-d9ea-0310-8a92-e5e31aec5664>2020-06-20 21:39:39 +0000
commit53b2035def91dc0fe6d8f68e4a34aca2acc79ec8 (patch)
tree03e818494b3390d3e7ed4aedac0a50f0b722f0a3 /Postman/PostmanLogFields.php
parent67430a4a94c041c57cb4043fcd05c85365ee17f5 (diff)
downloadPost-SMTP-53b2035def91dc0fe6d8f68e4a34aca2acc79ec8.zip
Email log improvements: Solution column, filter.
Some text clarify.
Diffstat (limited to 'Postman/PostmanLogFields.php')
-rw-r--r--Postman/PostmanLogFields.php12
1 files changed, 12 insertions, 0 deletions
diff --git a/Postman/PostmanLogFields.php b/Postman/PostmanLogFields.php
index 04d24a4..44bfee9 100644
--- a/Postman/PostmanLogFields.php
+++ b/Postman/PostmanLogFields.php
@@ -3,6 +3,7 @@ class PostmanLogFields {
private $fields = array(
'success' => 'sanitize_text_field',
+ 'solution' => [ 'PostmanLogFields', 'sanitize_message' ],
'from_header' => [ 'PostmanLogFields', 'email_header_sanitize' ],
'to_header' => [ 'PostmanLogFields', 'email_header_sanitize' ],
'cc_header' => [ 'PostmanLogFields', 'email_header_sanitize' ],
@@ -90,6 +91,17 @@ class PostmanLogFields {
return wp_kses( $message, $allowed_tags );
}
+ private function sanitize_html( $value ) {
+ $allowed_html = array(
+ 'a' => array(
+ 'href' => array(),
+ ),
+ 'br' => array(),
+ );
+
+ return wp_kses( $value, $allowed_html );
+ }
+
private function encode( $value ) {
if ( is_array( $value ) ) {
return wp_json_encode( $value );