You are here

function wunderground_weather_block_info in Wunderground weather 7

Implements hook_block_info().

File

./wunderground_weather.module, line 152
Wunderground weather module to display weather forecasts and current weather conditions in blocks.

Code

function wunderground_weather_block_info() {
  for ($f = 1; $f <= variable_get('wunderground_weather_block_forecast_amount', '1'); $f++) {
    $blocks['wunderground_weather_forecast_' . $f] = array(
      'info' => t('Wunderground Weather Forecast !amount', array(
        '!amount' => $f,
      )),
      'cache' => DRUPAL_NO_CACHE,
    );
  }
  for ($t = 1; $t <= variable_get('wunderground_weather_block_current_amount', '1'); $t++) {
    $blocks['wunderground_weather_current_' . $t] = array(
      'info' => t('Wunderground Current Weather !amount', array(
        '!amount' => $t,
      )),
      'cache' => DRUPAL_NO_CACHE,
    );
  }
  return $blocks;
}