123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172 |
- <?php
- if (!defined('STATUSNET') && !defined('LACONICA')) {
- exit(1);
- }
- class GroupsByPostsSection extends GroupSection
- {
- function getGroups()
- {
- $limit = GROUPS_PER_SECTION;
- $qry = 'SELECT user_group.*, count(*) as value ' .
- 'FROM user_group JOIN group_inbox '.
- 'ON user_group.id = group_inbox.group_id ' .
- 'GROUP BY user_group.id,user_group.nickname,user_group.fullname,user_group.homepage,user_group.description,user_group.location,user_group.original_logo,user_group.homepage_logo,user_group.stream_logo,user_group.mini_logo,user_group.created,user_group.modified ' .
- 'ORDER BY value DESC LIMIT ' . $limit;
- $group = Memcached_DataObject::cachedQuery('User_group',
- $qry,
- 3600);
- return $group;
- }
- function title()
- {
-
- return _('Active groups');
- }
- function divId()
- {
- return 'top_groups_by_post';
- }
- }
|