Beispiel #1
0
 function __construct($contentfield = NULL, $namefield = NULL, $mailfield = NULL, $urifield = NULL)
 {
     if ($contentfield && isset($_POST[$contentfield])) {
         $contentfield = $_POST[$contentfield];
     }
     if ($namefield && isset($_POST[$namefield])) {
         $namefield = $_POST[$namefield];
     }
     if ($mailfield && isset($_POST[$mailfield])) {
         $mailfield = $_POST[$mailfield];
     }
     if ($urifield && isset($_POST[$urifield])) {
         $urifield = $_POST[$urifield];
     }
     parent::__construct($contentfield, $namefield, $mailfield, $urifield, ServerRequest::getRequestIPs());
 }
Beispiel #2
0
 private function postFromFields(array $data, array $postdata, $content, $author, $email, $url, $ips)
 {
     $p = new SblamPost($content, $author, $email, $url, $ips);
     $p->setHeaders($data);
     $p->setTime($data['time']);
     $p->setPath($data['uri']);
     $p->setPost($postdata);
     $p->setInstallId($data['uid']);
     return $p;
 }