Пример #1
0
    /* Display the expand/contract all buttons. */
    print "<a href='#' onClick='expand_all()' class='nounderline'><img src='images/expand.png'> Expand All</a><br>";
    print "<a href='#' onClick='contract_all()' class='nounderline'><img src='images/contract.png'> Hide All</a><br>";
    print "<br>";
    /* Display any sub-albums. */
    clsAlbum::displayAlbums($arrAlbums, $objUser);
}
if ($strSubAction == 'userpictures') {
    if (!$objMember || $objMember->isNew()) {
        $objMember = $objUser;
    }
    $objTemplate->setText('PAGETITLE', $objMember->get('username') . "'s Pictures");
    $objBreadcrumbs->add('Members', 'index.php?action=members');
    $objBreadcrumbs->add($objMember->get('username'), 'index.php?action=members&subaction=view&' . $objGroup->getIDPair());
    $objBreadcrumbs->add("Pictures", "index.php?action=albums&subaction=userpictures&" . $objMember->getIDPair());
    clsPicture::displayPictures(clsAlbum::getPicturesByUser($objUser, $objMember));
}
if ($strSubAction == 'grouppictures') {
    $objTemplate->setText('PAGETITLE', "Pictures in " . $objGroup->get('name'));
    $objBreadcrumbs->add('Groups', 'index.php?action=groups');
    $objBreadcrumbs->add($objGroup->get('name'), 'index.php?action=groups&subaction=view&' . $objGroup->getIDPair());
    $objBreadcrumbs->add("Pictures", "index.php?action=albums&subaction=userpictures&" . $objMember->getIDPair());
    clsPicture::displayPictures(clsGroup::getPicturesByGroup($objUser, $objGroup));
}
if ($strSubAction == 'newpictures') {
    if ($objUser == null) {
        throw new Exception('exception_accessdenied');
    }
    $objTemplate->setText('PAGETITLE', "New Pictures");
    $objMiniMenu->add('Mark all as seen', "index.php?action=albums&subaction=seen");
    $objBreadcrumbs->add("New pictures", "index.php?action=albums&subaction=newpictures&" . $objMember->getIDPair());