Drupal 7 - add apple touch icon to print head output #drupal #d7 #iOS
<?php
function THEMENAME_preprocess_html(&$variables, $hook) {
// add apple touch icon to print_head
$apple_icon = array(
'#tag' => 'link',
'#attributes' => array(
'rel' => 'apple-touch-icon-precomposed',
'href' => '/' . path_to_theme() . '/apple-touch-icon-precomposed.png'
),
);
drupal_add_html_head($apple_icon, 'apple-touch-icon-precomposed');
}
?>