system_theme_data

  1. drupal
    1. drupal6
    2. drupal7
Versionen
drupal6 – drupal7 system_theme_data()

Collect data about all currently available themes.

Rückgabewert

Array of all available themes and their data.

▾ 8 functions call system_theme_data()

drupal_flush_all_caches in includes/common.inc
Flush all cached data on the site.
system_admin_theme_settings in modules/system/system.admin.inc
Form builder; This function allows selection of the theme to show in administration sections.
system_install in modules/system/system.install
Implementation of hook_install().
system_themes_form in modules/system/system.admin.inc
Menu callback; displays a listing of all themes.
system_theme_settings in modules/system/system.admin.inc
Form builder; display theme configuration for entire site and individual themes.
system_update_6008 in modules/system/system.install
Add info files to themes. The info and owner columns are added by update_fix_d6_requirements() in update.php to avoid a large number of error messages from update.php. All we need to do here is copy description to owner and then drop description.
system_update_6013 in modules/system/system.install
Rebuild cache data for theme system changes
update_get_projects in modules/update/update.compare.inc
Fetch an array of installed and enabled projects.

Code

modules/system/system.module, line 808

<?php
function system_theme_data() {
  // Scan the installation theme .info files and their engines.
  $themes = _system_theme_data();

  // Extract current files from database.
  system_get_files_database($themes, 'theme');

  db_query("DELETE FROM {system} WHERE type = 'theme'");

  foreach ($themes as $theme) {
    if (!isset($theme->owner)) {
      $theme->owner = '';
    }

    db_query("INSERT INTO {system} (name, owner, info, type, filename, status, throttle, bootstrap) VALUES ('%s', '%s', '%s', '%s', '%s', %d, %d, %d)", $theme->name, $theme->owner, serialize($theme->info), 'theme', $theme->filename, isset($theme->status) ? $theme->status : 0, 0, 0);
  }

  return $themes;
}
?>

Kommentare

Kommentar hinzufügen

Der Inhalt dieses Feldes wird nicht öffentlich zugänglich angezeigt.
  • Internet- und E-Mail-Adressen werden automatisch umgewandelt.
  • Zulässige HTML-Tags: <a> <em> <strong> <cite> <code> <ul> <ol> <li> <dl> <dt> <dd>
  • Zeilen und Absätze werden automatisch erzeugt.

Weitere Informationen über Formatierungsoptionen

Kommentar hinzufügen

Der Inhalt dieses Feldes wird nicht öffentlich zugänglich angezeigt.
  • Internet- und E-Mail-Adressen werden automatisch umgewandelt.
  • Zulässige HTML-Tags: <a> <em> <strong> <cite> <code> <ul> <ol> <li> <dl> <dt> <dd>
  • Zeilen und Absätze werden automatisch erzeugt.

Weitere Informationen über Formatierungsoptionen