|
Heartbroken Nickli Üyeden Alıntı
Bu forumdaki linkleri ve resimleri görebilmek için en az 25 mesajınız olması gerekir. |
nrt'ye Yazdırdığım scriptlerden bir Diğeri.
Shell üzerinde mail Komutlarıyla ,
İşlem yapar.
E-Posta'ya Ek ekleyebilir,
Çoklu e-posta Gönderebilir.
Kanalda ve Bot özelinde işler.
Kullanım Şekli:
.eposta -başlık <bu e-posta başlığı> -konu <bu postanız> -kime <gönderilecek e-posta adresi>
e-postanıza ek (attachment) eklemek istiyorsanız:
.eposta -başlık <bu e-posta başlığı> -konu <bu postanız> -kime <gönderilecek e-posta adresi> -ek </eklenecek/dosya/dizini/dosyanız>
birden fazla adrese gönderilecekse, e-posta adreslerinin aralarına virgül ekleyerek yazın. birinci@[Üye Olmadan Linkleri Göremezsiniz. Üye Olmak için TIKLAYIN...]s.com,ikinci@[Üye Olmadan Linkleri Göremezsiniz. Üye Olmak için TIKLAYIN...]s.net
Script Budur : [Üye Olmadan Linkleri Göremezsiniz. Üye Olmak için TIKLAYIN...] |
@
[Üye Olmadan Linkleri Göremezsiniz. Üye Olmak için TIKLAYIN...] Bu TCL'yi Tek Bir Kanal Üzerinde Çalıştırmamız Mümkündür ki ? Örneğin ; #Opers' de... Kod: Kodu kopyalamak için üzerine çift tıklayın!
setudef flag eposta
set ozelmsg 1
bind pub - .eposta posta_mail_pub
if {$ozelmsg >= "1"} {
bind msg - .eposta posta_mail_msg
}
proc posta_mail_pub {nick uhost hand chan text} {
if {![channel get $chan eposta]} { return 0 }
posta_mail $nick $uhost $hand $chan $text
}
proc posta_mail_msg {nick uhost hand text} {
posta_mail $nick $uhost $hand $nick $text
}
proc posta_mail {nick uhost hand chan text} {
set txt [split $text]
regsub -all -- {\s+} $txt " " txt
regexp {!?-başlık\s([^\-]+)\-} $txt "" subj
regexp {!?-kime\s([^\s]+)} $txt "" addr
regexp {!?-konu\s([^\-]+)\-} $txt "" konu
regexp {!?-ek\s(.*)} $txt "" ek
if {[string is space -strict $text]} {
puthelp "privmsg $chan :Kullanımı : $::lastbind -başlık <bu e-posta başlığı> -konu <bu postanız> -kime <gönderilecek e-posta adresi>"
puthelp "privmsg $chan :e-postanıza ek (attachment) eklemek istiyorsanız:"
puthelp "privmsg $chan :.eposta -başlık <bu e-posta başlığı> -konu <bu postanız> -kime <gönderilecek e-posta adresi> -ek </eklenecek/dosya/dizini/dosyanız>"
return
}
if {([regexp {^-başlık$} [lindex $txt 0]] eq "0") || $subj eq ""} {
puthelp "privmsg $chan :Kullanımı : $::lastbind -başlık <bu e-posta başlığı> -konu <bu postanız> -kime <gönderilecek e-posta adresi>"
puthelp "privmsg $chan :e-postanıza ek (attachment) eklemek istiyorsanız:"
puthelp "privmsg $chan :.eposta -başlık <bu e-posta başlığı> -konu <bu postanız> -kime <gönderilecek e-posta adresi> -ek </eklenecek/dosya/dizini/dosyanız>"
return
}
if {$addr eq "" || ![string match "*@*.*" $addr] || ![regexp {^[^@]+@[^\.]+\.(?:com|net|org|tc|uk|tr|info|edu)} $addr]} {
puthelp "privmsg $chan :-kime seçeneğinden sonra ,gönderilecek kişinin geçerli bir e-posta adresini girmelisiniz."
puthelp "privmsg $chan :birden fazla adrese gönderilecekse, e-posta adreslerinin aralarına virgül ekleyerek yazın. \
birinci@
[Üye Olmadan Linkleri Göremezsiniz. Üye Olmak için TIKLAYIN...]s.com,ikinci@
[Üye Olmadan Linkleri Göremezsiniz. Üye Olmak için TIKLAYIN...]s.net ... gibi."
return 0
}
if {"-ek" in $txt && ![regexp {^/.+?$} $ek]} {
puthelp "privmsg $chan :-ek eklenecek dosyanın dizini olarak girilmelidir.\
Örneğin bot'un .conf dosyasını e-postaya eklenmek isteniyorsa:"
puthelp "privmsg $chan :.eposta -başlık başlığım -konu konusu -kime adamin@
[Üye Olmadan Linkleri Göremezsiniz. Üye Olmak için TIKLAYIN...]ne.org -ek /home/benim-yerim/eggdrop/eggdrop.conf"
return
}
if {"-ek" in $txt} {
set cmd [list echo [trans $konu] | mail -s [trans $subj] -c [concat $addr] -a {*}$ek $addr]
catch { eval exec $cmd } output
} else {
set cmd [list echo [trans $konu] | mail -s [trans $subj] [concat $addr]]
catch { eval exec $cmd } output
}
if {$output ne ""} {
puthelp "privmsg $chan :hata oluştu: $output"
} else {
puthelp "privmsg $chan :e-posta'nız başarıyla gönderildi."
}
}
proc trans {str} {
return [string map [list ğ g Ğ G ı i İ I ö o Ö O ü u Ü U ş s Ş S ç c Ç C] $str]
}
putlog "[file tail [info script]] ok..."