0

When I go into ibm both in website and mobile I see two different links

http://www.ibm.com/us/en/

http://m.ibm.com/us/en/

How iphone detects mobile version?

http://m.ibm.com/us/en/

I'am working on my project to do different sites but dont know to implement it for iphone since i am not sure how iphone redirects to m.ibm.com

<head><meta content="text/html; charset=UTF-8" http-equiv="Content-Type"><meta content="public" name="Security"><meta content="IBM Corporation" name="DC.Publisher"><meta content="US" name="IBM.Country"><meta content="Joan Renner/Armonk/IBM" name="Owner"><meta content="2012-05-29" scheme="W3CDTF" name="IBM.Effective"><meta content="--" scheme="W3CDTF" name="IBM.Expires"><meta content="en-US" scheme="rfc1766" name="DC.Language"><meta content="2013-01-07" scheme="iso8601" name="DC.Date"><meta content="© Copyright IBM Corp. 2013, 2012" name="DC.Rights"><meta content="IBM101" scheme="IBM_SubjectTaxonomy" name="DC.Subject"><meta content="CT002" scheme="IBM_ContentClassTaxonomy" name="DC.Type"><meta content="" scheme="IBM_IndustryTaxonomy" name="IBM.Industry"><title>IBM - United States</title><link type="text/css" title="wireless" rel="stylesheet" media="all" href="//1.www.s81c.com/common/v17/css/mobile.css"><script type="text/javascript" src="//1.www.s81c.com/common/v17/mobile.js">//</script><script type="text/javascript" src="//1.www.s81c.com/common/js/dynamicnav/www/usen-utf8.js"></script><script type="text/javascript">window.onload = function() { ibmInit(); };</script><meta content="ibm.com wireless - Mobile Webmaster/Watson/IBM" name="Source"><meta content="noindex,nofollow" name="Robots"><meta name="viewport" content="user-scalable=no, initial-scale=1.0, maximum-scale=1.0, width=device-width"><meta name="apple-mobile-web-app-capable" content="yes"><link rel="alternate" type="text/html" title="Non Wireless" href="http://www.ibm.com/us/en/"><script type="text/javascript" src="chrome-extension://bfbmjmiodbnnpllbbbfblcplfjjepjdn/js/injected.js"></script></head>
Rushi
  • 4,553
  • 4
  • 33
  • 46
  • There may be no need for different sites, you can start building single site with responsive layouts. Check this http://twitter.github.com/bootstrap/ – Hary Jan 10 '13 at 06:14

2 Answers2

0

Use javascript to detect if the browser is an iPhone and then redirect to a new page if so.

<script type="text/javascript">
    if(window.navigator.userAgent.indexOf("iPhone") > -1){
        document.location.href = "http:/m.ibm.com/us/en/";
    }
</script>
Anthony Tietjen
  • 1,032
  • 2
  • 8
  • 19
  • thanks for your reply..is it possible to develop a web application where the intial home page in html and css but latter all the form field functionalities in jquery mobile to make better performance in mobile too....i mean the one half in normal jquery and another half in jquery mobile –  Jan 12 '13 at 01:47
0

Hope this link mobileesp helps you. It has code library which is available in several popular programming languages: PHP, Java, ASP.NET (C#), Python (for Django) for server-side detection, and JavaScript for more limited client-side detection.

viki
  • 1,178
  • 1
  • 17
  • 22