'default', 'font_family' => 'Arial, Helvetica, sans-serif', 'font_size' => '0.9', 'menu_style' => 0, 'show_logo_footer' => 1, 'show_breadcrumb' => 0, ); variable_set( str_replace('/', '_', 'theme_'. $theme_key .'_settings'), array_merge($defaults, theme_get_settings($theme_key)) ); theme_get_setting('', TRUE); } // Javascript Includes $menu_style = theme_get_setting('menu_style'); if ($menu_style == 0) { drupal_add_js($theme_path . '/menu/cssmenu/cssmenu.js', 'theme'); drupal_add_css($theme_path . '/menu/cssmenu/cssmenu.css', 'theme'); } elseif ($menu_style == 1){ drupal_add_js($theme_path . '/menu/splitmenu/splitmenu.js', 'theme'); drupal_add_css($theme_path . '/menu/splitmenu/splitmenu.css', 'theme'); } else { drupal_add_js($theme_path . '/menu/stmenu/stmenu.js', 'theme'); drupal_add_css($theme_path . '/menu/stmenu/stmenu.css', 'theme'); } // CSS Includes $color = theme_get_setting('color'); drupal_add_css($theme_path . '/css/'.$color.'-style.css', 'theme'); drupal_add_css($theme_path . '/css/custom.css', 'theme'); /*! * Dynamic display block preprocess functions * Copyright (c) 2008 - 2009 P. Blaauw All rights reserved. * Version 1.6 (01-OCT-2009) * Licenced under GPL license * http://www.gnu.org/licenses/gpl.html */ /** * Override or insert variables into the ddblock_cycle_block_content templates. * Used to convert variables from view_fields to slider_items template variables * * @param $vars * An array of variables to pass to the theme template. * */ function alphorn_preprocess_ddblock_cycle_block_content(&$vars) { if ($vars['output_type'] == 'view_fields') { $content = array(); // Add slider_items for the template // If you use the devel module uncomment the following line to see the theme variables // dsm($vars['settings']['view_name']); // dsm($vars['content'][0]); // If you don't use the devel module uncomment the following line to see the theme variables // drupal_set_message('
' . var_export($vars['settings']['view_name'], true) . ''); // drupal_set_message('
' . var_export($vars['content'][0], true) . ''); if ($vars['settings']['view_name'] == 'news_items') { if (!empty($vars['content'])) { foreach ($vars['content'] as $key1 => $result) { // add slide_image variable if (isset($result->node_data_field_pager_item_text_field_image_fid)) { // get image id $fid = $result->node_data_field_pager_item_text_field_image_fid; // get path to image $filepath = db_result(db_query("SELECT filepath FROM {files} WHERE fid = %d", $fid)); // use imagecache (imagecache, preset_name, file_path, alt, title, array of attributes) if (module_exists('imagecache') && is_array(imagecache_presets()) && $vars['imgcache_slide'] <> '
' . var_export($vars['pager_settings'], true) . ''); drupal_set_message('
' . var_export($vars['content'][0], true) . ''); if ($vars['pager_settings']['view_name'] == 'news_items') { if (!empty($vars['content'])) { foreach ($vars['content'] as $key1 => $result) { // add pager_item_image variable if (isset($result->node_data_field_pager_item_text_field_image_fid)) { $fid = $result->node_data_field_pager_item_text_field_image_fid; $filepath = db_result(db_query("SELECT filepath FROM {files} WHERE fid = %d", $fid)); // use imagecache (imagecache, preset_name, file_path, alt, title, array of attributes) if (module_exists('imagecache') && is_array(imagecache_presets()) && $vars['imgcache_pager_item'] <> '