$log = new RefererLog(); if ($log->open()) { $writer->write('<logs>'); $writer->write(CRLF); do { $writer->write('<referer>' . '<url>' . htmlspecialchars(Utils_Unicode::correct($log->url)) . '</url>' . '<referred>' . $log->referred . '</referred>' . '</referer>'); $writer->write(CRLF); } while ($log->shift()); $writer->write('</logs>'); $writer->write(CRLF); $log->close(); } $cmtNotified = new CommentNotified(); $cur_siteinfo = array(); $i = 0; if ($cmtNotified->open()) { $writer->write('<commentsNotified>'); $writer->write(CRLF); do { $writer->write('<comment>'); $writer->write('<id>' . $cmtNotified->id . '</id>'); $writer->write('<commenter>'); $writer->write('<name>' . htmlspecialchars(Utils_Unicode::correct($cmtNotified->name)) . '</name>'); $writer->write('<homepage>' . htmlspecialchars(Utils_Unicode::correct($cmtNotified->homepage)) . '</homepage>'); $writer->write('<ip>' . $cmtNotified->ip . '</ip>'); $writer->write('</commenter>'); $writer->write('<entry>' . $cmtNotified->entry . '</entry>'); $writer->write('<content>' . htmlspecialchars(Utils_Unicode::correct($cmtNotified->content)) . '</content>'); $writer->write('<password>' . htmlspecialchars($cmtNotified->password) . '</password>'); $writer->write('<parent>' . htmlspecialchars($cmtNotified->parent) . '</parent>'); $writer->write('<secret>' . $cmtNotified->secret . '</secret>');
function getCommentsNotified() { if (!Validator::number($this->id, 1)) { return null; } $comment = new CommentNotified(); if ($comment->open('siteid = ' . $this->id)) { return $comment; } }