function add_mobile_header_info() { $settings = $this->get_settings(); if ($this->get_active_device_class() == "ipad") { if ($settings->glossy_bookmark_icon) { $bookmark_icon = "<link rel='apple-touch-icon' href='" . mobileview_get_site_menu_icon(MOBILEVIEW_ICON_TABLET_BOOKMARK) . "' />\n"; } else { $bookmark_icon = "<link rel='apple-touch-icon-precomposed' href='" . mobileview_get_site_menu_icon(MOBILEVIEW_ICON_TABLET_BOOKMARK) . "' />\n"; } } else { if ($settings->glossy_bookmark_icon) { $bookmark_icon = "<link rel='apple-touch-icon' href='" . mobileview_get_site_menu_icon(MOBILEVIEW_ICON_BOOKMARK) . "' />\n"; } else { $bookmark_icon = "<link rel='apple-touch-icon-precomposed' href='" . mobileview_get_site_menu_icon(MOBILEVIEW_ICON_BOOKMARK) . "' />\n"; } } echo apply_filters('mobileview_bookmark_meta', $bookmark_icon); // Add the default stylesheet to the end, use min if available $minfile = TEMPLATEPATH . '/style.min.css'; if (file_exists($minfile)) { $this->css_files[] = mobileview_get_bloginfo('template_directory') . '/style.min.css?ver=' . mobileview_refreshed_files(); } else { $this->css_files[] = mobileview_get_bloginfo('template_directory') . '/style.css?ver=' . mobileview_refreshed_files(); } // Check for an active skin if ($settings->current_theme_skin != 'none') { $current_theme = $this->get_current_theme_info(); if (isset($current_theme->skins[$settings->current_theme_skin])) { $this->css_files[] = $current_theme->skins[$settings->current_theme_skin]->skin_url; } } $this->css_files = apply_filters('mobileview_theme_css_files', $this->css_files); foreach ($this->css_files as $css) { echo "<link rel='stylesheet' type='text/css' media='screen' href='{$css}' />\n"; } }
<!-- Depreciated in favor of add2home script, configure customizations in theme.js --> <?php if (mobile_view_show_webapp_notice()) { ?> <div id="web-app-overlay"> <img src="<?php mobileview_bloginfo('template_directory'); ?> /images/web-app-bubble-arrow.png" alt="bubble-arrow" id="bubble-arrow" /> <a href="#" id="close-wa-overlay">X</a> <img src="<?php echo mobileview_get_site_menu_icon(MOBILEVIEW_ICON_BOOKMARK); ?> " alt="bookmark-icon" id="bookmark-icon" /> <h2><?php mobileview_bloginfo('site_title'); ?> </h2> <h3><?php _e("is now web-app enabled!", "mobileviewlang"); ?> </h3> <p><?php echo sprintf(__("Save %s as a web-app on your Home Screen.", "mobileviewlang"), mobileview_get_bloginfo('site_title')); ?> </p> <p><?php _e("Tap the center button below, then Add to Home Screen.", "mobileviewlang"); ?> </p> </div>
function mobileview_page_get_icon() { global $mobileview; if (mobileview_page_has_icon()) { if (mobileview_is_custom_page_template()) { $page_id = mobileview_get_custom_page_template_id(); } else { $page_id = get_the_ID(); } // If we're not in the loop yet, let's grab the first post and then rewind if (!$page_id) { if (have_posts()) { the_post(); rewind_posts(); $page_id = get_the_ID(); } } $settings = mobileview_get_settings(); return mobileview_get_site_menu_icon($page_id); } else { return false; } }