mirror of
https://bitbucket.org/jsuto/piler.git
synced 2024-12-25 18:10:11 +01:00
nested mime parsing fixes in the gui
This commit is contained in:
parent
0392e60dba
commit
8e4dda968a
@ -139,6 +139,7 @@ class ModelSearchMessage extends Model {
|
||||
$qp = $base64 = 0;
|
||||
$has_text_plain = 0;
|
||||
$rfc822 = 0;
|
||||
$_1st_header = 1;
|
||||
|
||||
$from = $to = $subject = $date = $message = "";
|
||||
|
||||
@ -152,7 +153,7 @@ class ModelSearchMessage extends Model {
|
||||
$l .= "\n";
|
||||
|
||||
if(($l[0] == "\r" && $l[1] == "\n" && $is_header == 1) || ($l[0] == "\n" && $is_header == 1) ){
|
||||
$is_header = 0;
|
||||
$is_header = $_1st_header = 0;
|
||||
|
||||
if($rfc822 == 1) { $rfc822 = 0; $is_header = 1; }
|
||||
|
||||
@ -211,10 +212,12 @@ class ModelSearchMessage extends Model {
|
||||
$l = preg_replace("/</", "<", $l);
|
||||
$l = preg_replace("/>/", ">", $l);
|
||||
|
||||
if($state == "FROM"){ $from .= preg_replace("/\r|\n/", "", $l); }
|
||||
if($state == "TO"){ $to .= preg_replace("/\r|\n/", "", $l); }
|
||||
if($state == "SUBJECT"){ $subject .= preg_replace("/\r|\n/", "", $l); }
|
||||
if($state == "DATE"){ $date .= preg_replace("/\r|\n/", "", $l); }
|
||||
if($_1st_header == 1) {
|
||||
if($state == "FROM"){ $from .= preg_replace("/\r|\n/", "", $l); }
|
||||
if($state == "TO"){ $to .= preg_replace("/\r|\n/", "", $l); }
|
||||
if($state == "SUBJECT"){ $subject .= preg_replace("/\r|\n/", "", $l); }
|
||||
if($state == "DATE"){ $date .= preg_replace("/\r|\n/", "", $l); }
|
||||
}
|
||||
}
|
||||
else {
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user