You are here

function weather_get_locations_in_use in Weather 7

Get all currently used locations for a display.

Parameters

string $display_type: Display type.

int $display_number: Display number.

Return value

array Array of sorted locations.

1 call to weather_get_locations_in_use()
weather_block_view in ./weather.module
Implement hook_block_view().

File

./weather.module, line 431
Display current weather data from many places in the world.

Code

function weather_get_locations_in_use($display_type, $display_number) {
  return db_query('SELECT * FROM {weather_location}
    WHERE display_type=:type AND display_number=:number ORDER BY weight ASC, real_name ASC', array(
    ':type' => $display_type,
    ':number' => $display_number,
  ));
}