Skip navigation
Help

theme_uc_price

6 uc_store.module theme_uc_price($value, $context, $options)
7 uc_store.theme.inc theme_uc_price($variables)

Displays a price in the standard format and with consistent markup.

Parameters

$variables: An associative array containing:

  • price: A numerical price value.
  • suffixes: An array of suffixes to be attached to this price.

Related topics

11 theme calls to theme_uc_price()

File

ubercart/uc_store/uc_store.theme.inc, line 18
Theme functions for the uc_store module.

Code

function theme_uc_price($variables) {
  $output = '<span class="uc-price">' . uc_currency_format($variables['price']) . '</span>';
  if (!empty($variables['suffixes'])) {
    $output .= '<span class="price-suffixes">' . implode(' ', $variables['suffixes']) . '</span>';
  }
  return $output;
}