domain_theme_lookup($domain_id = NULL, $theme = NULL, $clear = FALSE)
domain/domain_theme/domain_theme.module, line 147
Get domain theme information
$domain_id The domain_id taken from {domain}. Optional.
$theme The string representation of a {domain_theme} entry. Optional.
$clear A boolean flag to clear the static variable if necessary. Not used. Here for consistency.
An array containing the requested row from the {domain_theme} table. Returns -1 on failure.
<?php
function domain_theme_lookup($domain_id = NULL, $theme = NULL, $clear = FALSE) {
if (!is_null($domain_id)) {
$return = db_fetch_array(db_query("SELECT domain_id, theme, settings FROM {domain_theme} WHERE domain_id = %d", $domain_id));
}
else if (!is_null($theme)) {
$return = db_fetch_array(db_query("SELECT domain_id, theme, settings FROM {domain_theme} WHERE theme= '%s'", $theme));
}
if (empty($return)) {
$return = -1;
}
return $return;
}
?>