Add vCard template
[squirrelmail.git] / templates / default / vcard.tpl
1 <?php
2 /**
3 * vcard.tpl
4 *
5 * Description
6 *
7 * The following variables are available in this template:
8 *
9 * @copyright &copy; 1999-2006 The SquirrelMail Project Team
10 * @license http://opensource.org/licenses/gpl-license.php GNU Public License
11 * @version $Id$
12 * @package squirrelmail
13 * @subpackage templates
14 */
15
16 /** add required includes **/
17
18 /** extract template variables **/
19 extract($t);
20
21 /** Begin template **/
22 ?>
23 <div id="vCard">
24 <table cellspacing="0" class="table1">
25 <tr>
26 <td class="header1">
27 <?php echo _("Viewing a Business Card") ; ?> - <a href="<?php echo $view_message_link; ?>"><?php echo _("View message"); ?></a>
28 </td>
29 </tr>
30 <tr>
31 <td>
32 <table cellspacing="0">
33 <?php
34 foreach ($vcard as $field=>$value) {
35 ?>
36 <tr>
37 <td class="fieldName">
38 <?php echo $field; ?>:
39 </td>
40 <td class="fieldValue">
41 <?php echo $value; ?>
42 </td>
43 </tr>
44 <?php
45 }
46 ?>
47 </table>
48 </td>
49 </tr>
50 <tr>
51 <td>
52 <a href="<?php echo $download_link; ?>"><?php echo _("Download this as a file"); ?></a>
53 </td>
54 </tr>
55 </table>
56 <form action="../src/addressbook.php" method="post" name="f_add">
57 <input type="hidden" name="addaddr[firstname]" value="<?php echo $firstname; ?>" />
58 <input type="hidden" name="addaddr[lastname]" value="<?php echo $lastname; ?>" />
59 <table cellspacing="0" class="table1">
60 <tr>
61 <td class="header1">
62 <?php echo _("Add to address book"); ?>
63 </td>
64 </tr>
65 <tr>
66 <td>
67 <table cellspacing="0">
68 <tr>
69 <td class="fieldName">
70 <?php echo _("Nickname"); ?>
71 </td>
72 <td class="fieldValue">
73 <input type="text" name="addaddr[nickname]" value="<?php echo $nickname; ?>" size="20" />
74 </td>
75 </tr>
76 <tr>
77 <td class="fieldName">
78 <?php echo _("Email"); ?>
79 </td>
80 <td class="fieldValue">
81 <input type="text" name="addaddr[email]" value="<?php echo $email; ?>" size="20" />
82 </td>
83 </tr>
84 <tr>
85 <td class="fieldName">
86 <?php echo _("Additional Info"); ?>
87 </td>
88 <td class="fieldValue">
89 <?php
90 if (count($info) == 0) {
91 ?>
92 <input type="text" name="addaddr[label]" value="" size="20" />
93 <?php
94 } else {
95 ?>
96 <select name="addaddr[label]">
97 <?php
98 foreach ($info as $value=>$field) {
99 ?>
100 <option value="<?php echo $value; ?>"><?php echo $field; ?></option>
101 <?php
102 }
103 ?>
104 </select>
105 <?php
106 }
107 ?>
108 </td>
109 </tr>
110 </table>
111 </td>
112 </tr>
113 <tr>
114 <td>
115 <input type="submit" value="<?php echo _("Add to address book"); ?>" name="addaddr[SUBMIT]" id="addaddr_SUBMIT_" />
116 </td>
117 </tr>
118 </table>
119 </form>
120 </div>