Exemplo n.º 1
0
function black_lagoon_preprocess_page(&$vars)
{
    if (variable_get('theme_black_lagoon_first_install', TRUE)) {
        include_once 'theme-settings.php';
        _black_lagoon_install();
    }
    $result = db_select('node', 'n')->fields('n')->condition('type', 'imagen_para_slider', '=')->execute()->fetchAllAssoc('nid');
    if ($result) {
        foreach ($result as $key => $value) {
            $vars['slides'][$key] = node_load($key);
        }
    }
}
Exemplo n.º 2
0
/**
 * @file
 * Black Lagoon Theme
 * Created by Zyxware Technologies
 */
function black_lagoon_preprocess_page(&$vars)
{
    // Useful for devel default banners, remove before commit
    //   variable_del('theme_marinelli_first_install');
    // Chcek if is first setup of marinelli and install banners.
    if (variable_get('theme_black_lagoon_first_install', TRUE)) {
        include_once 'theme-settings.php';
        _black_lagoon_install();
    }
    //to print the banners
    $banners = black_lagoon_show_banners();
    $vars['banner'] = $banners;
    if (drupal_is_front_page()) {
        drupal_add_js(path_to_theme() . '/js/slide.js', 'file');
    }
    //$vars['main_links_tree'] = menu_tree(variable_get('menu_main_links_source', 'main-menu'));
    //print render ( $vars['main_links_tree']);
}