function _views_system_get_screenshot in Views System 6.2
Same name and namespace in other branches
- 6.3 views_system.module \_views_system_get_screenshot()
- 7.3 views_system.module \_views_system_get_screenshot()
Helper function; retrieves screenshot path of the theme.
1 call to _views_system_get_screenshot()
File
- ./
views_system.module, line 74 - This module extends the Views module and allows to create customized lists (pages, blocks) of modules, themes, and theme engines that are or have been installed in Drupal's file system.
Code
function _views_system_get_screenshot($info) {
if (!file_exists($info['screenshot'])) {
if (isset($info['base theme'])) {
$result = db_query('SELECT info FROM {system} WHERE name = "%s" and type = "theme"', $info['base theme']);
if ($system = db_fetch_object($result)) {
$screenshot = _views_system_get_screenshot(unserialize($system->info));
}
else {
$screenshot = NULL;
}
}
else {
$screenshot = NULL;
}
}
else {
$screenshot = $info['screenshot'];
}
return $screenshot;
}