You are here

function contemplate_get_templates in Content Templates (Contemplate) 5

Same name and namespace in other branches
  1. 6 contemplate.module \contemplate_get_templates()
  2. 7 contemplate.module \contemplate_get_templates()

Get all of the current templates Only used on admin page

Return value

unknown

1 call to contemplate_get_templates()
contemplate_admin in ./contemplate.module
Admin page... list out the node types

File

./contemplate.module, line 457
Create templates to customize teaser and body content.

Code

function contemplate_get_templates() {
  $result = db_query("SELECT * FROM {contemplate}");
  while ($r = db_fetch_object($result)) {
    $templates[$r->type]['teaser'] = $r->teaser;
    $templates[$r->type]['body'] = $r->body;
    $templates[$r->type]['rss'] = $r->rss;
    $templates[$r->type]['enclosure'] = $r->enclosure;
  }
  return $templates;
}