function staticmap_preset_exists in Static Map 7
Checks preset availability.
Parameters
string $value: Preset name.
Return value
bool Returns FALSE if not exixts, otherwise TRUE.
1 call to staticmap_preset_exists()
- staticmap_ctools_export_ui_form_validate in ./
staticmap.module - Validate handler for export UI form.
1 string reference to 'staticmap_preset_exists'
- staticmap_ctools_export_ui_form in ./
staticmap.module - Form for ctools export UI.
File
- ./
staticmap.module, line 582 - SiteMap module.
Code
function staticmap_preset_exists($value) {
$exists = db_query('SELECT name FROM {staticmap_presets} WHERE name = :name', array(
':name' => $value,
))
->fetchField();
if ($exists) {
return TRUE;
}
return FALSE;
}