You are here

function textimage_get_presets in Textimage 6.2

Same name and namespace in other branches
  1. 5.2 textimage_admin.inc \textimage_get_presets()
  2. 5 textimage.module \textimage_get_presets()
  3. 7.2 textimage.module \textimage_get_presets()
7 calls to textimage_get_presets()
textimage_field_formatter_info in ./textimage.module
Implementation of hook_field_formatter_info().
textimage_preset_edit in ./textimage_admin.inc
textimage_preset_list in ./textimage_admin.inc
textimage_theme in ./textimage.module
Implementation of hook_theme().
textimage_update_2 in ./textimage.install

... See full list

File

./textimage_admin.inc, line 642

Code

function textimage_get_presets() {
  static $presets = array();
  if (empty($presets)) {
    $result = db_query("SELECT pid, name, description, settings FROM {textimage_preset} ORDER BY name");
    $presets = array();
    while ($preset = db_fetch_object($result)) {
      $preset->settings = unserialize($preset->settings);
      $presets[$preset->name] = $preset;
    }
  }
  return $presets;
}