HEX
Server: LiteSpeed
System: Linux houston.panomity.com 6.8.0-100-generic #100-Ubuntu SMP PREEMPT_DYNAMIC Tue Jan 13 16:40:06 UTC 2026 x86_64
User: nudepix (1011)
PHP: 7.4.33
Disabled: pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals,pcntl_unshare,
Upload Files
File: //opt/proundcontra.mosmuc.de/pages/profile.php
<?php
class PageProfile extends Page
{
    public function __construct($row)
    {
        global $sDB, $sRequest, $sQuery, $sTemplate, $sUser;
        parent::__construct($row);

        $this->userId = $sRequest->getInt("userId");
        $this->user   = $sQuery->getUser("userId=".$this->userId);

        if ($this->user != $sUser) {
            $sTemplate->error($sTemplate->getString("ERROR_INVALID_PROFILE"));
        }

        // Optionally set a short URL if your user object supports it
        $this->setShortUrl($this->user->shortUrl());
    }

    public function getUserId()
    {
        return $this->userId;
    }

    public function getUser()
    {
        return $this->user;
    }

    public function title()
    {
        global $sTemplate;
        return $sTemplate->getString(
            "HTML_META_TITLE_PROFILE",
            ["[USERNAME]"],
            [$this->getUser()->getUserName()]
        );
    }

    public function getFollowedQuestions()
    {
        global $sDB, $sUser;

        $qF = [];

        $res = $sDB->exec("
            SELECT `questions`.*
            FROM `notifications`
            LEFT JOIN `questions` ON `questions`.questionId = `notifications`.`questionId`
            LEFT JOIN `user_votes` ON questions.questionId = user_votes.questionId
            WHERE `notifications`.`userId` = '".i($this->userId)."'
            GROUP BY questions.questionId
            ORDER BY argumentId, vote DESC;
        ");

        while ($row = mysqli_fetch_object($res)) {
            $q = new Question($row->questionId, $row);
            $qF[] = $q;
        }

        return $qF;
    }

    private $userId;
    private $user;
}
?>