Transfering netmail via EMSI

This commit is contained in:
Deon George
2021-07-17 15:48:07 +10:00
parent 6ce4e64cb6
commit 1fa566b26c
15 changed files with 226 additions and 83 deletions

View File

@@ -21,7 +21,7 @@ abstract class Process
*/
protected static function format_msg(string $text): string
{
$msg = utf8_decode(join("\n",static::msg_header()))."\n";
$msg = utf8_decode(join("\r",static::msg_header()))."\r";
$c = 0;
$offset = 0;
@@ -35,7 +35,7 @@ abstract class Process
}
// Look for a return
$return = strpos($text,"\n",$offset);
$return = strpos($text,"\r",$offset);
if ($return !== FALSE)
$return -= $offset;
@@ -55,13 +55,13 @@ abstract class Process
$subtext = substr($text,$offset,$space);
}
$msg .= $ll.$subtext."\n";
$msg .= $ll.$subtext."\r";
$offset += strlen($subtext)+1;
}
// In case our text is shorter than the loo
for ($c; $c<count(static::$logo);$c++)
$msg .= utf8_decode(Arr::get(static::$logo,$c))."\n";
$msg .= utf8_decode(Arr::get(static::$logo,$c))."\r";
return $msg;
}