54 $this->lang_variables_as_fallback = $a_status;
83 $this->data = $a_data;
99 if (!is_array($this->amail[$a_lang]))
101 require_once(
'./Services/WebDAV/classes/class.ilObjDiskQuotaSettings.php');
103 $this->amail[
"body"] = trim($this->amail[
"body"]);
104 $this->amail[
"subject"] = trim($this->amail[
"subject"]);
107 return $this->amail[$a_lang];
125 if ($amail[
'body'] ==
'' || $amail[
'subject'] ==
'')
128 $lang = $ilSetting->get(
'language');
132 $lang = $this->data[
'language'];
137 ($amail[
'body'] ==
'' || $amail[
'subject'] ==
''))
139 $lang = $this->data[
'language'];
143 $mail_subject = $tmp_lang->txt(
'disk_quota_mail_subject');
146 $mail_body = $tmp_lang->txt(
'disk_quota_mail_body_salutation').
' '.
$data[
'firstname'].
' '.
$data[
'lastname'].
",\n\n".
147 $tmp_lang->txt(
'disk_quota_body_text1').
"\n\n".
148 $tmp_lang->txt(
'disk_quota_body_text2').
"\n".
149 ILIAS_HTTP_PATH.
'/login.php?client_id='.CLIENT_ID.
"\n";
150 $mail_body .= $tmp_lang->txt(
'login').
': '.
$data[
'firstname'].
"\n";
152 $mail_body .= $tmp_lang->txt(
'disk_quota_mail_body_text3').
"\n\r";
163 include_once
'Services/Mail/classes/class.ilMimeMail.php';
165 $mmail->autoCheck(
false);
166 $mmail->From($ilSetting->get(
'admin_email'));
167 $mmail->Subject($mail_subject);
168 $mmail->To($this->data[
'email']);
169 $mmail->Body($mail_body);
172 include_once
'Services/Mail/classes/class.ilMail.php';
174 $mail->sendMail($this->data[
'login'],
"",
"",$mail_subject,$mail_body,array(),array(
"normal"));
182 if ($this->tmp_lng == null || $this->tmp_lng->lang_key != $a_lang)
193 $tmp_lang = $this->
getLng($a_lang);
196 switch ($this->data[
'gender'])
198 case "f" : $gender_salut = $a_amail[
"sal_f"];
200 case "m" : $gender_salut = $a_amail[
"sal_m"];
202 default : $gender_salut = $a_amail[
"sal_g"];
204 $gender_salut = trim($gender_salut);
206 $a_string = str_replace(
"[MAIL_SALUTATION]", $gender_salut, $a_string);
207 $a_string = str_replace(
"[LOGIN]", $this->data[
'login'], $a_string);
208 $a_string = str_replace(
"[FIRST_NAME]", $this->data[
'firstname'], $a_string);
209 $a_string = str_replace(
"[LAST_NAME]", $this->data[
'lastname'], $a_string);
211 $a_string = str_replace(
"[EMAIL]", $this->data[
'email'], $a_string);
212 $a_string = str_replace(
"[ILIAS_URL]",
213 ILIAS_HTTP_PATH.
"/login.php?client_id=".CLIENT_ID, $a_string);
214 $a_string = str_replace(
"[CLIENT_NAME]", CLIENT_NAME, $a_string);
215 $a_string = str_replace(
"[ADMIN_MAIL]", $ilSetting->get(
"admin_email"),
218 require_once
'classes/class.ilFormat.php';
219 $a_string = str_replace(
"[DISK_QUOTA]",
ilFormat::formatSize($this->data[
'disk_quota'],
'short',$tmp_lang), $a_string);
220 $a_string = str_replace(
"[DISK_USAGE]",
ilFormat::formatSize($this->data[
'disk_usage'],
'short',$tmp_lang), $a_string);
222 $disk_usage_details =
'';
223 foreach ($this->data[
'disk_usage_details'] as $details)
227 $a_string = str_replace(
"[DISK_USAGE_DETAILS]", $disk_usage_details, $a_string);