* [Friends] Members can now apply to be added to the contact list.
[pivip.git] / project / modules / friends / views / scripts / list / edit.phtml
blob49263d95039c927ccb1a0f2860d2386baea29666
1 <? if(0 < count($this->contacts)): ?>
2 <h1><?= $this->translate('Contacts'); ?></h1>
3 <ul>
4         <? foreach($this->contacts as $contact): ?>
5         <li><a href="<?= $this->url(array('friend' => urlencode($contact->website)),
6                                     'Friends_EditFriend'); ?>"
7                title="<?= $this->translate('Edit contact'); ?>"
8             ><?= $contact->name; ?></a>
9                 <sub class="options">
10                         <a href="<?= $this->url(array('friend'
11                                                         => urlencode($contact->website)),
12                                                 'Friends_DeleteFriend'); ?>"
13                            title="<?= $this->translate('Remove contact'); ?>"
14             ><?= $this->translate('Remove'); ?></a></sub>
15         </li>
16         <? endforeach; ?>
17 </ul>
18 <? endif;
19 if(0 < count($this->toApprove)): ?>
20 <h1><?= $this->translate('Pending approval'); ?></h1>
21 <ul>
22         <? foreach($this->toApprove as $contact):?>
23         <li><a href="<?= $this->url(array('friend' => urlencode($contact->website)),
24                                     'Friends_AddFriend'); ?>"
25                title="<?= $this->translate('Add contact'); ?>"
26             ><?= $contact->name; ?></a>
27                 <sub class="options">
28                         <a href="<?= $this->url(array('friend'
29                                                         => urlencode($contact->website)),
30                                                 'Friends_DeleteFriend'); ?>"
31                            title="<?= $this->translate('Reject this friend request'); ?>"
32             ><?= $this->translate('Reject'); ?></a></sub></li>
33         <? endforeach; ?>
34 </ul>
35 <? endif; ?>
36 <sub class="options">
37 <a href="<?= $this->url(array(), 'Friends_AddFriend'); ?>"
38    title="<?= $this->translate('Add a contact'); ?>"
39 ><?= $this->translate('Add a contact'); ?></a>
40 </sub>