+ $this->elementEnd('p');
+
+ $this->elementStart('p', array('id' => 'group_search'));
+ $this->element('a', array('href' => common_local_url('groupsearch'),
+ 'class' => 'more'),
+ _('Search for more groups'));
+ $this->elementEnd('p');
+
+ if (Event::handle('StartShowUserGroupsContent', array($this))) {
+ $offset = ($this->page-1) * GROUPS_PER_PAGE;
+ $limit = GROUPS_PER_PAGE + 1;
+
+ $groups = $this->user->getGroups($offset, $limit);
+
+ if ($groups) {
+ $gl = new GroupList($groups, $this->user, $this);
+ $cnt = $gl->show();
+ if (0 == $cnt) {
+ $this->showEmptyListMessage();
+ }
+ }