aboutsummaryrefslogtreecommitdiff
path: root/muamba-widget.tpl.php
blob: 3caf6148cea3ad75f4b2d3feb80643ddb91176e1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
<?php

/**
 * @file
 * Template for displaying the muamba widget.
 *
 * @todo: use $transaction
 *   Show item status: can it be requested?
 *   Is this item already requested?
 */

// Add javascript and CSS files
$path = drupal_get_path('module', 'muamba');
drupal_add_js($path  .'/muamba.js');
drupal_add_css($path .'/muamba.css');

$icon = theme('image',
  array(
    'path'  => $path .'/images/basket.png',
    'alt'   => t('Request item'),
    'title' => t('Request item'),
  )
);

$output  = '<div class="muamba-widget">';
$output .= l($icon, 'muamba/request/'. $nid, array('html' => TRUE));
$output .= '</div>';

print $output;