if ($count > 0) { include_once libfile('function/home'); $picturecatelist = array(); $aids = '['; $tmparray = array(); foreach (C::t('#sanree_brand#sanree_brand_album')->fetch_all_by_searchex($where, 'ishome desc,displayorder,albumid desc', ($page - 1) * $perpage, $perpage) as $key => $album) { if ($config['isbird']) { $album['thumbpic'] = pic_cover_get($album['pic'], 1); } else { $album['thumbpic'] = $isalbumthumb == 1 ? sr_albumimage($album['pic'], 160, 160) : pic_cover_get($album['pic'], 1); } $album['pic'] = pic_cover_get($album['pic'], 1); $picturecatelist[$key] = $album; $tmparray[] = "'{$album['albumid']}'"; } $aids .= implode($tmparray, ","); $aids .= ']'; $murl = getalbumitemurl($catid); $multi = multi($count, $perpage, $page, $murl); } if (!$config['isbird']) { require_once libfile('class/' . $plugin['identifier'] . '_menu', 'plugin/' . $plugin['identifier']); $menuclass = new sanree_brand_menu($plugin['identifier']); $menuclass->getmenu($brandresult, 'myalbum'); $brand_header = $menuclass->_brand_header; $brand_header_one = $menuclass->_brand_header_one; } $bid = $brandresult['bid']; $group = C::t('#sanree_brand#sanree_brand_group')->get_by_groupid($brandresult['groupid']); $allowbatchimage = intval($group['allowbatchimage']); include templateEx($plugin['identifier'] . ':' . $template . '/albumshow');
for ($itc = 0; $itc < 4; $itc++) { $wanted = 'static/image/common/nophoto.gif'; $albumcatelist[$itc] = array('name' => srlang('no_pic'), 'pic' => $wanted, 'url' => $adminadurl); } $where = array(); $where[] = 'uid=' . $brandresult['uid']; $where[] = 'bid=' . $bid; include_once libfile('function/home'); $picshowtipformat = srlang('picshowtip'); foreach (C::t('#sanree_brand#sanree_brand_album_category')->fetch_all_by_searchd($where, 'displayorder,dateline DESC') as $data) { if ($isalbumthumb == 1) { $data['pic'] = sr_albumimage($data['pic'], 120, 120); } else { $data['pic'] = empty($data['pic']) ? 'static/image/common/nophoto.gif' : pic_cover_get($data['pic'], 1); } $data['url'] = getalbumitemurl($data[catid]); $wherealbumsub = array(); $wherealbumsub[] = 'catid = ' . $data[catid]; $data['num'] = C::t('#sanree_brand#sanree_brand_album')->count_by_wherec($wherealbumsub); $data['picshowtip'] = str_replace("{picnum}", $data['num'], $picshowtipformat); $albumcatelist[$ri] = $data; $ri++; } } $brandresult[albumurl] = getalbumurl($brandresult[bid]); $where = array(); $where[] = 'uid=' . $brandresult['uid']; $where[] = 'bid=' . $bid; $albumcat = C::t('#sanree_brand#sanree_brand_album_category')->fetch_all_by_searchd($where, 'displayorder,dateline DESC'); $bids = array(); foreach ($albumcat as $data) {