remove old readme
[atutor.git] / docs / themes / mobile / social / sgroup_list.tmpl.php
1 <script src="<?php echo AT_SOCIAL_BASENAME; ?>lib/js/livesearch.js" type="text/javascript"></script>
2 <?php 
3         //Add Friends Template
4         //Generate a random number for the search input name fields, so that the browser will not remember any previous entries.
5         $rand = md5(rand(0, time())); 
6         if ($this->rand_key != ''){
7                 $last_search = $_POST['search_friends_'.$this->rand_key];
8         } else {
9                 $last_search = $_POST['search_friends_'.$rand]; 
10         }
11 ?>
12
13 <div class="input-form" style="float:right; width:34%;padding:1em;min-height:4.5em;">
14         <div class="contentrow">
15                 <h3><?php echo _AT('search_for_friends'); ?></h3>
16                 <form action="<?php echo url_rewrite(AT_SOCIAL_BASENAME.'groups/list.php');?>" method="POST" id="search_friends_form">
17                         <label for="searchFriends" style="display:none;"><?php echo _AT('search'); ?></label>
18                         <input type="text" size="60" name="search_friends_<?php echo $rand;?>" id="search_friends" value="<?php echo $last_search; ?>" onkeyup="showResults(this.value, 'livesearch', '<?php echo AT_SOCIAL_BASENAME; ?>groups/list.php')"/>
19                         <input type="submit" name="search" value="<?php echo _AT('search'); ?>">
20                         <input type="hidden" name="rand_key" value="<?php echo $rand; ?>" />
21                         <input type="hidden" name="id" value="<?php echo $this->grp_obj->getID(); ?>" />                        
22                         <div id="livesearch"></div>
23                 </form>
24         </div>
25 </div>
26 <div class="" style="float:left; width:59%">
27         <div class="headingbox"><h3><?php echo _AT('connections'); ?></h3></div>
28         <div class="contentbox">
29         <?php 
30         if (!empty($this->grp_members)):
31                 echo "<h4>"._AT('there_are_entries', sizeof($this->grp_members))."</h4>";
32                 foreach ($this->grp_members as $id=>$person_obj): 
33         ?>
34         <div class="contact_mini" >
35                 <?php if($_SESSION['member_id']==$this->grp_obj->getUser()): ?>
36                 <div style="float:right;"><a href="<?php echo AT_SOCIAL_BASENAME;?>groups/list.php?remove=yes<?php echo SEP;?>id=<?php echo $this->grp_obj->getID(); ?><?php echo SEP;?>member_id=<?php echo $person_obj->getID(); ?>"><img src="<?php echo $_base_href.AT_SOCIAL_BASENAME; ?>images/b_drop.png" alt="<?php echo _AT('remove_group_member'); ?>" title="<?php echo _AT('remove_group_member'); ?>" border="0"/></a> </div>
37                 <?php endif; ?>
38                 <div>
39                         <div style="float:left;"><?php echo printSocialProfileImg($person_obj->getID()); ?></div>
40                         <div style="padding-left:0.5em; float:left;">
41                                 <?php 
42                                         $profile = $person_obj->getDetails();
43                                         echo printSocialName($person_obj->getID()) . '<br/>';
44                                         echo $profile['country'] . ' ' . $profile['province'] . '<br/>';
45                                 ?>
46                         </div>
47                         <div style="clear:both;"></div><br/>
48                 </div>
49         </div>
50         <?php 
51                 endforeach; 
52         endif;
53         ?>
54         </div>
55         <!--
56         <div style="float:right;">
57                 [-- TODO: Paginator --]
58         </div>
59         -->
60 </div>
61