## odbieranie maila zlozonego przy pomocy pkg: pop3 i mime # package re tls package re pop3 #% 1.6.3 source pop3_tls.tcl # dodaje do pakietu pop3 obsluge tls/ssl !!! package re mime #% 1.5.2 set pass "???" set p [pop3::open -ssl 1 pop3.amu.edu.pl mhanckow $pass 995] pop3::list $p #% 1 26074 # + wyswietla liste maili w folderze INBOX oraz ich dlugosci... set m [pop3::retrieve $p 1] set m1 [mime::initialize -string [lindex $m 0]] mime::getproperty $m1 content #% multipart/alternative set m2 [mime::getproperty $m1 parts] #% ::mime::1-1 ::mime::1-2 mime::getproperty [lindex $m2 0] content #% text/plain mime::getproperty [lindex $m2 1] content #% multipart/related set m3 [mime::getproperty [lindex $m2 1] parts] #% ::mime::1-2-1 ::mime::1-2-2 mime::getproperty [lindex $m3 0] content #% text/html mime::getproperty [lindex $m3 1] content #% image/jpeg package re Img image create photo img1 -data [mime::getbody [lindex $m3 1]] label .l1 -image img1; pack .l1 mime::getbody [lindex $m3 0] -decode # + pokazuje html