function icons() { global $ss_settings; $favicon_item = $ss_settings['favicon']; $apple_icon_item = $ss_settings['apple_icon']; // Add the favicon if (!empty($favicon_item['url']) && $favicon_item['url'] != '') { $favicon = StacheStack_Image::_resize($favicon_item['url'], 32, 32, true, false); echo '<link rel="shortcut icon" href="' . $favicon['url'] . '" type="image/x-icon" />'; } // Add the apple icons if (!empty($apple_icon_item['url'])) { $iphone_icon = StacheStack_Image::_resize($apple_icon_item['url'], 57, 57, true, false); $iphone_icon_retina = StacheStack_Image::_resize($apple_icon_item['url'], 57, 57, true, true); $ipad_icon = StacheStack_Image::_resize($apple_icon_item['url'], 72, 72, true, false); $ipad_icon_retina = StacheStack_Image::_resize($apple_icon_item['url'], 72, 72, true, true); ?> <!-- For iPhone --><link rel="apple-touch-icon-precomposed" href="<?php echo $iphone_icon['url']; ?> "> <!-- For iPhone 4 Retina display --><link rel="apple-touch-icon-precomposed" sizes="114x114" href="<?php echo $iphone_icon_retina['url']; ?> "> <!-- For iPad --><link rel="apple-touch-icon-precomposed" sizes="72x72" href="<?php echo $ipad_icon['url']; ?> "> <!-- For iPad Retina display --><link rel="apple-touch-icon-precomposed" sizes="144x144" href="<?php echo $ipad_icon_retina['url']; ?> "> <?php } }
/** * Image functions */ function stachestack_image_resize($data) { _stachestack_deprecated_function(__FUNCTION__, '3.2', 'StacheStack_Image::image_resize()'); return StacheStack_Image::image_resize($data); }
function featured_image() { global $ss_framework, $ss_settings; $data = array(); if (!has_post_thumbnail() || '' == get_the_post_thumbnail()) { return; } $data['width'] = StacheStack_Layout::content_width_px(); if (is_singular()) { // Do not process if we don't want images on single posts if ($ss_settings['feat_img_post'] != 1) { return; } $data['url'] = wp_get_attachment_url(get_post_thumbnail_id()); if ($ss_settings['feat_img_post_custom_toggle'] == 1) { $data['width'] = $ss_settings['feat_img_post_width']; } $data['height'] = $ss_settings['feat_img_post_height']; } else { // Do not process if we don't want images on post archives if ($ss_settings['feat_img_archive'] != 1) { return; } $data['url'] = wp_get_attachment_url(get_post_thumbnail_id()); if ($ss_settings['feat_img_archive_custom_toggle'] == 1) { $data['width'] = $ss_settings['feat_img_archive_width']; } $data['height'] = $ss_settings['feat_img_archive_height']; } $image = StacheStack_Image::image_resize($data); echo $ss_framework->clearfix() . '<a href="' . get_permalink() . '"><img class="featured-image ' . $ss_framework->float_class('left') . '" src="' . $image['url'] . '" /></a>'; }