From 481c8498dd0b2aac06e34393d3cffe3bdabf767e Mon Sep 17 00:00:00 2001 From: Klaus-Uwe Mitterer Date: Sat, 5 Sep 2020 21:36:07 +0200 Subject: [PATCH] Forgot subject handling... --- Mail.class.php | 6 ++++++ Request.class.php | 4 ++++ 2 files changed, 10 insertions(+) diff --git a/Mail.class.php b/Mail.class.php index e2cd652..bdc6680 100644 --- a/Mail.class.php +++ b/Mail.class.php @@ -79,6 +79,8 @@ class Mail { $mail->add_ccs($req->get_ccs()); $mail->add_bccs($req->get_bccs()); + $mail->set_subject($req->get_subject()); + $html = $req->prepare_html($req->has_config("urlbeforestring")); $text = $req->prepare_text(!$req->has_config("noconversion"), $req->has_config("urlbeforestring")); $mail->add_content($html, $text); @@ -97,4 +99,8 @@ class Mail { function set_from($email, $name) { $this->mailer->setFrom($email, $name); } + + function set_subject($subject) { + $this->mailer->Subject = $subject; + } } \ No newline at end of file diff --git a/Request.class.php b/Request.class.php index 0255da8..539de73 100644 --- a/Request.class.php +++ b/Request.class.php @@ -132,6 +132,10 @@ class Request { } } + function get_subject() { + return $this->json["subject"]; + } + function get_text($conversion=true, $urlbeforestring=false) { if ($this->json["text"] && $this->json["texturl"]) { if ($urlbeforestring) {