'3', // 1, 2, 3 (the depth of the menu, 1 being no dropdown) 'headerMenu1_display' => 'pages', // pages, categories 'headerMenu1_sortBy' => 'post_title', // [CATEGORIES]: name, ID, count, slug [PAGES]: post_title, ID, post_name (slug), menu_order (the page's Order value) 'headerMenu1_sortOrder' => 'asc', // asc, desc 'headerMenu1_alignment' => 'right', // right, left 'headerMenu1_show' => true, 'headerMenu1_disableParentPageLink' => false, 'headerMenu1_exclude_categories' => '', 'headerMenu1_exclude_pages' => '', 'headerMenu2_dropdown' => '3', // 1, 2, 3 (the depth of the menu, 1 being no dropdown) 'headerMenu2_display' => 'categories', // pages, categories 'headerMenu2_sortBy' => 'name', // [CATEGORIES]: name, ID, count, slug [PAGES]: post_title, ID, post_name (slug), menu_order (the page's Order value) 'headerMenu2_sortOrder' => 'asc', // asc, desc 'headerMenu2_displayHomeButton' => true, 'headerMenu2_displaySeparators' => true, 'headerMenu2_disableParentPageLink' => false, 'headerMenu2_exclude_categories' => '', 'headerMenu2_exclude_pages' => '', 'headerImage' => 'lightBlue', //lightBlue, darkBlue 'commentDisplay' => 'alt', // alt, left, right 'commentDateFormat' => 'timePassed', // timePassed, date 'comments_hideWhenDisabledOnPages' => true, 'comments_hideWhenDisabledOnPosts' => false, 'footerStyle' => 'style1', // style1, style2 'appendToPageTitle' => 'blogName', // blogName, custom 'appendToPageTitleCustom' => '', 'sidebarDisplay' => 'right', // right, left, none 'sidebarWidth' => 'normal', // small, normal, large 'sidebar_showDefault' => true, 'sidebar_showRSSButton' => true, 'sidebar_showTwitterButton' => false, 'sidebar_twitterURL' => '', 'sidebar_showFacebookButton' => false, 'sidebar_facebookURL' => '', 'sidebar_displayButtonTexts' => false, 'enableIE6optimization' => true, 'postsShowAuthor' => true, 'postsShowTime' => false, 'posts_showTopPostLinks' => false, 'posts_showBottomPostLinks' => true, 'pages_showInfoBar' => false, 'customCSS' => false, 'customCSS_input' => '', 'customCSS_useFilesystem' => false, 'pagination' => true, 'pagination_pageRange' => 2, //the number of page buttons to show before and after the current page button 'pagination_pageAnchors' => 1, //the number of buttons to always show at the beginning and end of the pagination bar 'pagination_pageGap' => 1 //the number of pages in a gap before an ellipsis is added ); $optionsSaved = false; function arjuna_create_options() { // Default values $options = $GLOBALS['_arjunaDefaultOptions']; // Overridden values $DBOptions = get_option('arjuna_options'); if ( !is_array($DBOptions) ) $DBOptions = array(); // Merge // Change since Arjuna 1.2: Values that are not used anymore will be deleted foreach ( $options as $key => $value ) if ( isset($DBOptions[$key]) ) $options[$key] = $DBOptions[$key]; update_option('arjuna_options', $options); return $options; } function arjuna_get_options() { static $return = false; if($return !== false) return $return; $options = get_option('arjuna_options'); if(!empty($options) && count($options) == count($GLOBALS['_arjunaDefaultOptions'])) $return = $options; else $return = $GLOBALS['_arjunaDefaultOptions']; return $return; } function arjuna_add_theme_options() { global $optionsSaved; if(isset($_POST['arjuna_save_options'])) { $options = arjuna_create_options(); //Menu 1 dropdown $validOptions = array('1', '2', '3'); if ( in_array($_POST['headerMenu1_dropdown'], $validOptions) ) $options['headerMenu1_dropdown'] = $_POST['headerMenu1_dropdown']; else $options['headerMenu1_dropdown'] = '3'; //Menu 1 display $validOptions = array('pages', 'categories'); if ( in_array($_POST['headerMenu1_display'], $validOptions) ) $options['headerMenu1_display'] = $_POST['headerMenu1_display']; else $options['headerMenu1_display'] = 'pages'; if ($options['headerMenu1_display']=='pages') { //Menu 1 sorting for PAGES $validOptions = array('post_title', 'ID', 'post_name', 'menu_order'); if ( in_array($_POST['headerMenu1_sortBy_pages'], $validOptions) ) $options['headerMenu1_sortBy'] = $_POST['headerMenu1_sortBy_pages']; else $options['headerMenu1_sortBy'] = $validOptions[0]; //Menu 1 sorting order $validOptions = array('asc', 'desc'); if ( in_array($_POST['headerMenu1_sortOrder_pages'], $validOptions) ) $options['headerMenu1_sortOrder'] = $_POST['headerMenu1_sortOrder_pages']; else $options['headerMenu1_sortOrder'] = $validOptions[0]; } elseif ($options['headerMenu1_display']=='categories') { //Menu 1 sorting for CATEGORIES $validOptions = array('name', 'ID', 'count', 'slug'); if ( in_array($_POST['headerMenu1_sortBy_categories'], $validOptions) ) $options['headerMenu1_sortBy'] = $_POST['headerMenu1_sortBy_categories']; else $options['headerMenu1_sortBy'] = $validOptions[0]; //Menu 1 sorting order $validOptions = array('asc', 'desc'); if ( in_array($_POST['headerMenu1_sortOrder_categories'], $validOptions) ) $options['headerMenu1_sortOrder'] = $_POST['headerMenu1_sortOrder_categories']; else $options['headerMenu1_sortOrder'] = $validOptions[0]; } //Menu 1 show if ($_POST['headerMenu1_show']) $options['headerMenu1_show'] = true; else $options['headerMenu1_show'] = false; //Menu 1 alignment $validOptions = array('right', 'left'); if ( in_array($_POST['headerMenu1_alignment'], $validOptions) ) $options['headerMenu1_alignment'] = $_POST['headerMenu1_alignment']; else $options['headerMenu1_alignment'] = $validOptions[0]; // Menu 1 - Disable Parent Page Links in if ($_POST['headerMenu1_disableParentPageLink']) $options['headerMenu1_disableParentPageLink'] = true; else $options['headerMenu1_disableParentPageLink'] = false; // Menu 1 - Exclude items if($_POST['headerMenu1_exclude_categories']) { $options['headerMenu1_exclude_categories'] = implode(',', $_POST['headerMenu1_exclude_categories']); } else $options['headerMenu1_exclude_categories'] = ''; if($_POST['headerMenu1_exclude_pages']) { $options['headerMenu1_exclude_pages'] = implode(',', $_POST['headerMenu1_exclude_pages']); } else $options['headerMenu1_exclude_pages'] = ''; //Menu 2 dropdown $validOptions = array('1', '2', '3'); if ( in_array($_POST['headerMenu2_dropdown'], $validOptions) ) $options['headerMenu2_dropdown'] = $_POST['headerMenu2_dropdown']; else $options['headerMenu2_dropdown'] = '3'; //Menu 2 display $validOptions = array('pages', 'categories'); if ( in_array($_POST['headerMenu2_display'], $validOptions) ) $options['headerMenu2_display'] = $_POST['headerMenu2_display']; else $options['headerMenu2_display'] = 'pages'; if ($options['headerMenu2_display']=='pages') { //Menu 2 sorting for PAGES $validOptions = array('post_title', 'ID', 'post_name', 'menu_order'); if ( in_array($_POST['headerMenu2_sortBy_pages'], $validOptions) ) $options['headerMenu2_sortBy'] = $_POST['headerMenu2_sortBy_pages']; else $options['headerMenu2_sortBy'] = $validOptions[0]; //Menu 2 sorting order $validOptions = array('asc', 'desc'); if ( in_array($_POST['headerMenu2_sortOrder_pages'], $validOptions) ) $options['headerMenu2_sortOrder'] = $_POST['headerMenu2_sortOrder_pages']; else $options['headerMenu2_sortOrder'] = $validOptions[0]; } elseif ($options['headerMenu2_display']=='categories') { //Menu 2 sorting for CATEGORIES $validOptions = array('name', 'ID', 'count', 'slug'); if ( in_array($_POST['headerMenu2_sortBy_categories'], $validOptions) ) $options['headerMenu2_sortBy'] = $_POST['headerMenu2_sortBy_categories']; else $options['headerMenu2_sortBy'] = $validOptions[0]; //Menu 2 sorting order $validOptions = array('asc', 'desc'); if ( in_array($_POST['headerMenu2_sortOrder_categories'], $validOptions) ) $options['headerMenu2_sortOrder'] = $_POST['headerMenu2_sortOrder_categories']; else $options['headerMenu2_sortOrder'] = $validOptions[0]; } //Menu 2 Home Icon if ($_POST['headerMenu2_displayHomeButton']) $options['headerMenu2_displayHomeButton'] = true; else $options['headerMenu2_displayHomeButton'] = false; //Menu 2 Home Icon if ($_POST['headerMenu2_displaySeparators']) $options['headerMenu2_displaySeparators'] = true; else $options['headerMenu2_displaySeparators'] = false; // Menu 2 - Disable Parent Page Links in if ($_POST['headerMenu2_disableParentPageLink']) $options['headerMenu2_disableParentPageLink'] = true; else $options['headerMenu2_disableParentPageLink'] = false; // Menu 2 - Exclude items if($_POST['headerMenu2_exclude_categories']) { $options['headerMenu2_exclude_categories'] = implode(',', $_POST['headerMenu2_exclude_categories']); } else $options['headerMenu2_exclude_categories'] = ''; if($_POST['headerMenu2_exclude_pages']) { $options['headerMenu2_exclude_pages'] = implode(',', $_POST['headerMenu2_exclude_pages']); } else $options['headerMenu2_exclude_pages'] = ''; //Header Image $validOptions = array('lightBlue', 'darkBlue', 'khaki', 'seaGreen'); if ( in_array($_POST['headerImage'], $validOptions) ) $options['headerImage'] = $_POST['headerImage']; else $options['headerImage'] = $validOptions[0]; //Comment display $validOptions = array('alt', 'left', 'right'); if ( in_array($_POST['commentDisplay'], $validOptions) ) $options['commentDisplay'] = $_POST['commentDisplay']; else $options['commentDisplay'] = 'alt'; // Comment display if ($_POST['comments_hideWhenDisabledOnPages']) $options['comments_hideWhenDisabledOnPages'] = true; else $options['comments_hideWhenDisabledOnPages'] = false; if ($_POST['comments_hideWhenDisabledOnPosts']) $options['comments_hideWhenDisabledOnPosts'] = true; else $options['comments_hideWhenDisabledOnPosts'] = false; //Footer style $validOptions = array('style1', 'style2'); if ( in_array($_POST['footerStyle'], $validOptions) ) $options['footerStyle'] = $_POST['footerStyle']; else $options['footerStyle'] = 'style1'; //Comment date format $validOptions = array('timePassed', 'date'); if ( in_array($_POST['commentDateFormat'], $validOptions) ) $options['commentDateFormat'] = $_POST['commentDateFormat']; else $options['commentDateFormat'] = 'timePassed'; //Append to page title $validOptions = array('blogName', 'custom'); if ( in_array($_POST['appendToPageTitle'], $validOptions) ) $options['appendToPageTitle'] = $_POST['appendToPageTitle']; else $options['appendToPageTitle'] = 'blogName'; if ($_POST['appendToPageTitle']=='custom') { $options['appendToPageTitleCustom'] = $_POST['appendToPageTitleCustom']; } //Sidebar display $validOptions = array('right', 'left', 'none'); if ( in_array($_POST['sidebarDisplay'], $validOptions) ) $options['sidebarDisplay'] = $_POST['sidebarDisplay']; else $options['sidebarDisplay'] = $validOptions[0]; // Whether or not to show the default bars (if no widget bars are defined) if ($_POST['sidebar_showDefault']) $options['sidebar_showDefault'] = true; else $options['sidebar_showDefault'] = false; // Sidebar: RSS Button if ($_POST['sidebar_showRSSButton']) $options['sidebar_showRSSButton'] = true; else $options['sidebar_showRSSButton'] = false; // Sidebar: Twitter Button if ($_POST['sidebar_showTwitterButton']) { $twitterURL = trim($_POST['sidebar_twitterURL']); $options['sidebar_showTwitterButton'] = true; if ( !preg_match('/twitter\.com/i', $twitterURL) ) { if(!preg_match('/\.com/i', $twitterURL)) { //Add the twitter host name $twitterURL = "http://twitter.com/" . $twitterURL; } else { $options['sidebar_showTwitterButton'] = false; $twitterURL = ""; } } elseif ( !preg_match('/http[s]?\:\/\//i', $twitterURL) ) { $twitterURL = "http://" . $twitterURL; } elseif ( empty($twitterURL) ) { $options['sidebar_showTwitterButton'] = false; } $options['sidebar_twitterURL'] = $twitterURL; } else $options['sidebar_showTwitterButton'] = false; // Sidebar: Facebook Button if ($_POST['sidebar_showFacebookButton']) { $facebookURL = trim($_POST['sidebar_facebookURL']); $options['sidebar_showFacebookButton'] = true; if ( !preg_match('/facebook\./i', $facebookURL) ) { $twitterURL = "http://facebook.com/" . $facebookURL; } elseif ( !preg_match('/http[s]?\:\/\//i', $facebookURL) ) { $facebookURL = "http://" . $facebookURL; } elseif ( empty($facebookURL) ) { $options['sidebar_showFacebookButton'] = false; } $options['sidebar_facebookURL'] = $facebookURL; } else $options['sidebar_showFacebookButton'] = false; if ($_POST['sidebar_displayButtonTexts']) $options['sidebar_displayButtonTexts'] = true; else $options['sidebar_displayButtonTexts'] = false; //Sidebar Width $validOptions = array('normal', 'small', 'large'); if ( in_array($_POST['sidebarWidth'], $validOptions) ) $options['sidebarWidth'] = $_POST['sidebarWidth']; else $options['sidebarWidth'] = $validOptions[0]; // IE Optimization if ($_POST['enableIE6optimization']) $options['enableIE6optimization'] = true; else $options['enableIE6optimization'] = false; // Posts, Show Author if ($_POST['postsShowAuthor']) $options['postsShowAuthor'] = true; else $options['postsShowAuthor'] = false; // Posts, Show Time if ($_POST['postsShowTime']) $options['postsShowTime'] = true; else $options['postsShowTime'] = false; if ($_POST['pages_showInfoBar']) $options['pages_showInfoBar'] = true; else $options['pages_showInfoBar'] = false; //Navigation links to previous and next posts if ($_POST['posts_showTopPostLinks']) $options['posts_showTopPostLinks'] = true; else $options['posts_showTopPostLinks'] = false; if ($_POST['posts_showBottomPostLinks']) $options['posts_showBottomPostLinks'] = true; else $options['posts_showBottomPostLinks'] = false; if ($_POST['pagination']=='1') { $options['pagination'] = true; $validOptions = array(1,2,3,4,5); if ( in_array($_POST['pagination_pageRange'], $validOptions) ) $options['pagination_pageRange'] = $_POST['pagination_pageRange']; else $options['pagination_pageRange'] = 3; $validOptions = array(1,2,3); if ( in_array($_POST['pagination_pageAnchors'], $validOptions) ) $options['pagination_pageAnchors'] = $_POST['pagination_pageAnchors']; else $options['pagination_pageAnchors'] = 1; $validOptions = array(1,2,3); if ( in_array($_POST['pagination_pageGap'], $validOptions) ) $options['pagination_pageGap'] = $_POST['pagination_pageGap']; else $options['pagination_pageGap'] = 1; } else $options['pagination'] = false; //Custom CSS if ($_POST['customCSS']) { if (trim($_POST['customCSS_input'])) { $options['customCSS'] = true; $input = trim($_POST['customCSS_input']); if (is_writable(dirname(__FILE__).'/')) { //create a new CSS file $handle = fopen(dirname(__FILE__).'/user-style.css', 'w'); fwrite($handle, $input); fclose($handle); $options['customCSS_useFilesystem'] = true; } else { $options['customCSS_useFilesystem'] = false; $options['customCSS_input'] = $input; } } } else $options['customCSS'] = false; update_option('arjuna_options', $options); $optionsSaved = true; } add_theme_page(__('Arjuna Options', 'Arjuna'), __('Arjuna Options', 'Arjuna'), 'edit_themes', basename(__FILE__), 'arjuna_add_theme_page'); } function arjuna_add_theme_page () { global $optionsSaved; $options = arjuna_get_options(); if ( $optionsSaved ) echo '

'.__('The Arjuna options have been saved.', 'Arjuna').'

'; ?>

SRS Solutions'); ?>
*/ ?>

style="display:none;"> */ ?>



style="display:none;">
style="display:none;">
style="display:none;">


style="display:none;">



style="display:none;"> */ ?>


style="display:none;">
style="display:none;">
style="display:none;">


', 'Arjuna'); ?>
style="display:none;">



/>
/>
/>
/>

/>
/>
/>


sidebar_full_top: Recent Posts and Browse by Tags, sidebar_left: Categories, sidebar_right: Meta', 'Arjuna'); ?>






/>
/>
/>










/>
/>




'Sidebar Top', 'id'=>'sidebar_full_top', 'description'=>'This is the top widget bar in the sidebar, extending to full width of the sidebar.', 'before_widget' => '
', 'after_widget' => '
', 'before_title' => '

', 'after_title' => '

' )); register_sidebar(array( 'name'=>'Sidebar Left', 'id'=>'sidebar_left', 'description'=>'This is the widget bar on the left hand side in the sidebar. It appears right below the top widget bar.', 'before_widget' => '
', 'after_widget' => '
', 'before_title' => '

', 'after_title' => '

' )); register_sidebar(array( 'name'=>'Sidebar Right', 'id'=>'sidebar_right', 'description'=>'This is the widget bar on the right hand side in the sidebar. It appears right below the top widget bar, next to the left widget bar.', 'before_widget' => '
', 'after_widget' => '
', 'before_title' => '

', 'after_title' => '

' )); register_sidebar(array( 'name'=>'Sidebar Bottom', 'id'=>'sidebar_full_bottom', 'description'=>'This is the bottom widget bar in the sidebar, extending to full width of the sidebar. It will appear below the left and right widget bars.', 'before_widget' => '
', 'after_widget' => '
', 'before_title' => '

', 'after_title' => '

' )); /* register_sidebar(array( 'name'=>'header_bar', 'before_widget' => '
', 'after_widget' => '
', 'before_title' => '

', 'after_title' => '

', )); register_sidebar(array( 'name'=>'footer_bar', 'before_widget' => '
', 'after_widget' => '
', 'before_title' => '

', 'after_title' => '

', )); */ } $GLOBALS['content_width'] = $content_width = 600; // Localization function theme_init(){ load_theme_textdomain('Arjuna', get_template_directory() . '/languages'); } add_action ('init', 'theme_init'); //CSS for plugin page add_action('admin_print_styles', 'arjuna_admin_initCSS'); function arjuna_admin_initCSS() { wp_enqueue_style('arjunaAdminCSS', get_bloginfo('stylesheet_directory').'/admin.css'); } //JS for plugin page add_action('admin_print_scripts', 'arjuna_admin_initJS'); function arjuna_admin_initJS() { wp_enqueue_script('arjunaAdminJS', get_bloginfo('stylesheet_directory').'/admin.js'); } //for WordPress versions below 2.7, include a legacy comments file because threaded comments are not supported yet add_filter( 'comments_template', 'legacy_comments' ); function legacy_comments( $file ) { //is WordPress 2.7 or below? if ( !function_exists('wp_list_comments') ) $file = TEMPLATEPATH . '/comments_legacy.php'; return $file; } // custom comments function arjuna_get_comment($comment, $args, $depth) { $arjunaOptions = get_option('arjuna_options'); $GLOBALS['comment'] = $comment; $commentClass = 'comment'; ?>
  • id="comment-">
    comment_date_gmt))); } else { print __('on', 'Arjuna').' '.get_comment_time(get_option('date_format')); } ?>. $depth, 'max_depth' => $args['max_depth']))) ?> comment_approved == '0'): ?>

    , WP, as strange as this is, adds it automatically ?> ' . $text . '', $link, $text); } function arjuna_get_time_passed($pastTime) { $currentTime = time(); $seconds = $currentTime - $pastTime; if ($seconds > 28944000) { //older than 335 days $years = round($seconds/31557600); //365.25 days return $years==1 ? __('1 year', 'Arjuna') : sprintf(__('%d years', 'Arjuna'), $years); } if ($seconds > 2592000) { //older than 30 days $months = round($seconds/2629800); //1 month (average) return $months==1 ? __('1 month', 'Arjuna') : sprintf(__('%d months', 'Arjuna'), $months); } if ($seconds > 518400) { //older than 6 days $weeks = round($seconds/604800); //1 week return $weeks==1 ? __('1 week', 'Arjuna') : sprintf(__('%d weeks', 'Arjuna'), $weeks); } if ($seconds > 82800) { //older than 23 hours $days = round($seconds/86400); //1 day return $days==1 ? __('1 day', 'Arjuna') : sprintf(__('%d days', 'Arjuna'), $days); } if ($seconds > 3540) { //older than 59 minutes $hours = round($seconds/3600); //1 hour return $hours==1 ? __('1 hour', 'Arjuna') : sprintf(__('%d hours', 'Arjuna'), $hours); } if ($seconds > 59) { //older than 59 seconds $minutes = round($seconds/60); //1 minute return $minutes==1 ? __('1 minute', 'Arjuna') : sprintf(__('%d minutes', 'Arjuna'), $minutes); } return $seconds==1 ? __('1 second', 'Arjuna') : sprintf(__('%d seconds', 'Arjuna'), $seconds); } function has_pages() { global $wp_query; if ( !is_single() && $wp_query->max_num_pages > 1 ) return true; return false; } function arjuna_get_previous_page_link($label) { global $paged; if ( !is_single() && $paged > 1 ) { echo ''. preg_replace( '/&([^#])(?![a-z]{1,8};)/', '&$1', $label ) .''; } } function arjuna_get_next_page_link($label) { global $paged, $wp_query; $max_page = $wp_query->max_num_pages; if ( !$paged ) $paged = 1; $nextpage = intval($paged) + 1; if ( !is_single() && ( empty($paged) || $nextpage <= $max_page) ) { echo ''. preg_replace('/&([^#])(?![a-z]{1,8};)/', '&$1', $label) .''; } } // Returns true if there is at least one other post than the one being viewed currently function arjuna_has_other_posts() { if (get_adjacent_post(false, '', false)) return true; if (get_adjacent_post(false, '', true)) return true; return false; } function arjuna_get_next_post_link($label) { $post = get_adjacent_post(false, '', false); if (!$post) return; echo ''; } function arjuna_get_previous_post_link($label) { $post = get_adjacent_post(false, '', true); if (!$post) return; echo ''; } function arjuna_get_appendToPageTitle() { $arjunaOptions = get_option('arjuna_options'); if ($arjunaOptions['appendToPageTitle']=='blogName') { echo " - "; bloginfo('name'); } elseif ($arjunaOptions['appendToPageTitle']=='custom' && !empty($arjunaOptions['appendToPageTitleCustom'])) { echo " - " . $arjunaOptions['appendToPageTitleCustom']; } } function arjuna_get_custom_CSS() { $arjunaOptions = arjuna_get_options(); if($arjunaOptions['customCSS'] && $arjunaOptions['customCSS_useFilesystem'] && file_exists(dirname(__FILE__).'/user-style.css')) return ''; if($arjunaOptions['customCSS'] && !$arjunaOptions['customCSS_useFilesystem'] && $arjunaOptions['customCSS_input']) return ''; return ''; } function arjuna_get_pagination($previousLabel, $nextLabel) { $arjunaOptions = arjuna_get_options(); global $wp_query; $currentPage = get_query_var('paged') ? intval(get_query_var('paged')) : 1; $postsPerPage = intval(get_query_var('posts_per_page')); $totalPages = intval(ceil($wp_query->found_posts/$postsPerPage)); if ($totalPages > 1) { $output = ''; $output .= ''; echo $output; } return; } function arjuna_get_comment_pagination() { if ( !is_singular() || !get_option('page_comments') ) return; if(get_comment_pages_count() <= 1) return; echo '
    '; if(function_exists('paginate_comments_links')) { echo '' . __('Comment Pages:', 'Arjuna') . ''; paginate_comments_links('prev_text='.__('Previous', 'Arjuna').'&next_text='.__('Next', 'Arjuna').''); } else { echo ''; previous_comments_link(__('Older Comments', 'Arjuna')); echo ''; echo ''; next_comments_link(__('Newer Comments', 'Arjuna')); echo ''; } echo '
    '; } function arjuna_get_edit_link($label) { global $post; if ( !$url = get_edit_post_link( $post->ID ) ) return; return ''.$label.''; } //Try to detect if IE6 or below is the user's browser. This allows for Arjuna to optimize IE6 output and significantly reduce bandwidth for IE6 users. function arjuna_isIE6() { $userAgent = strtolower($_SERVER['HTTP_USER_AGENT']); if ( ( strpos($userAgent, 'msie 6') !== false || strpos($userAgent, 'msie 5') !== false ) && strpos($userAgent, 'opera') === false && strpos($userAgent, 'msie 7') === false && strpos($userAgent, 'msie 8') === false ) return true; return false; }