b3c07fdc |
1 | <?php |
2 | |
3 | /** |
4 | * input.tpl |
5 | * |
6 | * Template for constructing an input tag. |
7 | * |
8 | * The following variables are available in this template: |
9 | * + $type - The type of input tag being created |
10 | * + $aAttribs - Any extra attributes: an associative array, where |
11 | * keys are attribute names, and values (which are |
12 | * optional and might be null) should be placed |
13 | * in double quotes as attribute values (optional; |
14 | * may not be present) |
15 | * |
1977ab55 |
16 | * @copyright 1999-2010 The SquirrelMail Project Team |
b3c07fdc |
17 | * @license http://opensource.org/licenses/gpl-license.php GNU Public License |
18 | * @version $Id$ |
19 | * @package squirrelmail |
20 | * @subpackage templates |
21 | */ |
22 | |
23 | |
24 | // retrieve the template vars |
25 | // |
26 | extract($t); |
27 | |
28 | |
29 | echo '<input type="' . $type . '"'; |
30 | foreach ($aAttribs as $key => $value) { |
31 | echo ' ' . $key . (is_null($value) ? '' : '="' . $value . '"'); |
32 | } |
33 | echo ' />'; |
34 | |
35 | |