質問編集履歴
2
ヘッダー取得方法を変更してみましたが、どれも同一の内容でした。
test
CHANGED
File without changes
|
test
CHANGED
@@ -111,3 +111,23 @@
|
|
111
111
|
// var_dump($header_list)."<hr>";
|
112
112
|
|
113
113
|
```
|
114
|
+
|
115
|
+
|
116
|
+
|
117
|
+
###追記
|
118
|
+
|
119
|
+
imap_open()でヘッダーを取得してみましたが、取得出来た内容は同一でした。
|
120
|
+
|
121
|
+
|
122
|
+
|
123
|
+
```
|
124
|
+
|
125
|
+
#imap_open
|
126
|
+
|
127
|
+
$mbox = imap_open("{localhost:110/pop3/notls}INBOX", "user", "pass");
|
128
|
+
|
129
|
+
echo imap_fetchheader($mbox,1);
|
130
|
+
|
131
|
+
imap_close($mbox);
|
132
|
+
|
133
|
+
```
|
1
ヘッダ情報を取得している箇所のソースコードを追記しました。
test
CHANGED
File without changes
|
test
CHANGED
@@ -65,3 +65,49 @@
|
|
65
65
|
|
66
66
|
|
67
67
|
```
|
68
|
+
|
69
|
+
|
70
|
+
|
71
|
+
###ヘッダー情報を取得する箇所のソースコード
|
72
|
+
|
73
|
+
```
|
74
|
+
|
75
|
+
$account = array(
|
76
|
+
|
77
|
+
'host' => 'localhost',
|
78
|
+
|
79
|
+
'port' => '110',
|
80
|
+
|
81
|
+
'username' => 'username',
|
82
|
+
|
83
|
+
'password' => 'password',
|
84
|
+
|
85
|
+
);
|
86
|
+
|
87
|
+
|
88
|
+
|
89
|
+
$pop3 =& new Net_POP3();
|
90
|
+
|
91
|
+
$pop3->connect($account['host'], $account['port']);
|
92
|
+
|
93
|
+
$pop3->login($account['username'], $account['password']);
|
94
|
+
|
95
|
+
$n_msg = $pop3->numMsg();
|
96
|
+
|
97
|
+
$header_list = $pop3->getParsedHeaders($n_msg);
|
98
|
+
|
99
|
+
$body = mb_convert_encoding($pop3->getBody($n_msg), "euc-jp", "jis");
|
100
|
+
|
101
|
+
$body = htmlspecialchars($body, ENT_QUOTES, "euc-jp");
|
102
|
+
|
103
|
+
$pop3->disconnect();
|
104
|
+
|
105
|
+
|
106
|
+
|
107
|
+
$from = mb_decode_mimeheader($header_list['From']);
|
108
|
+
|
109
|
+
|
110
|
+
|
111
|
+
// var_dump($header_list)."<hr>";
|
112
|
+
|
113
|
+
```
|