Вход Регистрация
Файл: adultscript-2.0.3-pro/files/mobile/components/users_photos.php
Строк: 36
<?php
defined
('_VALID') or die('Restricted Access!');
class 
VComponent_mobile_users_photos extends VComponent_mobile_users
{
    public function 
__construct()
    {
        
parent::__construct(true);
    }

    public function 
render()
    {
        
$errors        = array();
        
$messages    = array();
        
        
$user_id    = (int) $this->user['user_id'];

        
$url        'users/'.$this->username.'/photos/';
        if (!
VUri::match($url)) {
            
$this->notfound();
        }

        
$this->update_views($user_id);

        if (
$this->show($this->user['show_albums'])) {
            if (
$this->tpl->total_public_albums $this->get_albums_count($user_id'public')) {
                
$this->tpl->public_albums     $this->get_albums($user_id'public'2);
            }

            if (
$this->tpl->total_private_albums $this->get_albums_count($user_id'private')) {
                
$this->tpl->private_albums    $this->get_albums($user_id'private'2);
            }
        }

        if (
$this->show($this->user['show_photo_favorites'])) {
            if (
$this->tpl->total_photos $this->get_photo_favorites_count($user_id)) {
                
$this->tpl->photos $this->get_photo_favorites($user_id2);
            }
        }

        
$this->tpl->menu            'community';
        
$this->tpl->submenu            'photos';

        
$this->tpl->meta_title      __('photos-meta-title', array($this->user['username'], $this->tpl->mcfg['site_name']));
        
$this->tpl->meta_desc       __('photos-meta-desc', array($this->user['username'], $this->tpl->mcfg['meta_desc']));
        
$this->tpl->meta_keys       $this->mcfg['meta_keys'];

        
$this->tpl->canonical       BASE_URL.'/'.$url;

        
$this->tpl->errors          $errors;
        
$this->tpl->messages        $messages;    
        
$this->tpl->user            $this->user;
        
$this->tpl->username          e($this->user['username']);
        
$this->tpl->is_subscribed     $this->is_subscribed;
        
$this->tpl->is_friend         $this->is_friend;
        
$this->tpl->is_self           $this->is_self;
        
$this->tpl->is_moderator      $this->is_moderator;
        
$this->tpl->is_loggedin       $this->is_loggedin;
        
$this->tpl->is_blocked        $this->is_blocked;
        
$this->tpl->load(array('header''users_photos''footer'));
        
$this->tpl->display();    
    }
}
Онлайн: 1
Реклама