// append the required parameters
// TODO: there might be already a ? at the url,
// in that case use & instead
- var newUrl = oldUrl + '?width=500&height=500&template=colorbox';
+ var newUrl = oldUrl + '&template=colorbox';
// update the links href
$(this).attr('href', newUrl);
});
),
'file' => 'muamba.theme.inc',
),
+ 'muamba_colorbox_link' => array(
+ 'variables' => array(
+ 'path' => NULL,
+ 'text' => NULL,
+ ),
+ 'file' => 'muamba.theme.inc',
+ ),
);
}
}
return $block;
}
+
+/**
+ * Implements hook_privatemsg_view_alter()
+ *
+ * @todo
+ */
+function muamba_privatemsg_view_alter(&$content) {
+ $content['participants']['#markup'] = $content['participants']['#markup'] . 'TODO: Add here request management bar.';
+}
'user' => $transaction['user']->name,
'status' => t(muamba_statuses($transaction['status'])),
'actions' => implode($actions, ' | '),
+ //'thread' => theme('muamba_colorbox_link', array(
+ // 'path' => '/messages/view/'. $transaction['thread_id'],
+ // 'text' => t('view messages'),
+ //)),
'thread' => l(
t('view messages'),
'messages/view/'. $transaction['thread_id'],
return $output;
}
+
+/**
+ * Theme callback.
+ */
+function theme_muamba_colorbox_link($variables) {
+ $path = $variables['path'];
+ $text = $variables['text'];
+
+ $output = '<a href="'. $path .'?width=500&height=500&iframe=true';
+ $output .= '" class="colorbox-ajax colorbox-load">';
+ $output .= $text .'</a>';
+
+ return $output;
+}