"; GPrint($this->debugString); echo "
"; $body=preg_replace('/\-\-start\-<\/div>[\d\D]+\-\-end\-<\/div>/', "", $body); $body=preg_replace('/<.*?font-family:.*?,Helvetica,Arial[^\/]+<\/div>/', "", $body); $body=app_trim($body); $body=strip_tags($body,$allowed_tags); $body=app_trim($body); $body=preg_replace( "/[^\/]+<\/div>/i", "", $body ); $body=preg_replace( "/?[^\/]+<\/div><\/div>/i", "", $body ); $body=str_replace( '\s*)+/i", "", $body); $body=app_trim($body,''); $body=preg_replace( "/[\r\n]+/i", "", $body ); $body=nl2br($body); $body=preg_replace('/On .*?wrote:/i', "", $body); } function AddDebugLog($msg){ if($this->isDebugMode){ $msg="\n".date('Y-m-d H:i:s')." - ".$msg; file_put_contents(APPPATH."/logs/email_to_ticket.log",$msg,FILE_APPEND); $this->debugString.=$msg; } } }