Add iDevice detection to BY page template