<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Mobile Web Programming</title>
	<atom:link href="http://www.mobilexweb.com/feed" rel="self" type="application/rss+xml" />
	<link>http://www.mobilexweb.com</link>
	<description>Techniques and best practices for delivering the best possible experience for each mobile device</description>
	<lastBuildDate>Mon, 21 Nov 2011 14:43:16 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>iWebInspector: Debugging webapps and PhoneGap apps on iOS</title>
		<link>http://www.mobilexweb.com/blog/debugging-web-safari-phonegap-iphone-ipad</link>
		<comments>http://www.mobilexweb.com/blog/debugging-web-safari-phonegap-iphone-ipad#comments</comments>
		<pubDate>Mon, 21 Nov 2011 14:14:59 +0000</pubDate>
		<dc:creator>firt</dc:creator>
				<category><![CDATA[General]]></category>

		<guid isPermaLink="false">http://www.mobilexweb.com/?p=117</guid>
		<description><![CDATA[Tweet Debugging mobile web applications was always a painful process. In this post I&#8217;m presenting the free tool iWebInspector I&#8217;ve created to enable a full Web Inspector -including JavaScript debugging &#38; profiling- in Safari for iPhone and iPad and in PhoneGap apps. First of all, full credit of the hack behind the tool to Nathan de [...]]]></description>
			<content:encoded><![CDATA[
	<div style="float: right; margin: 10px">
		<a href="http://twitter.com/share" class="twitter-share-button" data-count="horizontal" data-text="iWebInspector: Debugging webapps and PhoneGap apps on iOS - Mobile Web Programming" data-url="http://www.mobilexweb.com/blog/debugging-web-safari-phonegap-iphone-ipad"  data-via="mobilexweb @firt" data-related="firt:Blog\\\\\\\\\\\\\\\'s author">Tweet</a>
	</div>
	<script type="text/javascript" src="http://platform.twitter.com/widgets.js"></script><p><a href="http://www.mobilexweb.com/wp-content/uploads/2011/11/icon.png"><img class="alignleft size-thumbnail wp-image-119" title="iWebInspector" src="http://www.mobilexweb.com/wp-content/uploads/2011/11/icon-150x150.png" alt="" width="90" height="90" /></a>Debugging mobile web applications was always a painful process. In this post I&#8217;m presenting the free tool <strong>iWebInspector</strong> I&#8217;ve created to enable a full Web Inspector -including JavaScript debugging &amp; profiling- in Safari for iPhone and iPad and in PhoneGap apps.</p>
<p><span id="more-117"></span><br />
First of all, full credit of the hack behind the tool to <a href="http://atnan.com/" target="_blank">Nathan de Vries</a>. He has discovered some days ago a private API and he has published a <a href="http://atnan.com/blog/2011/11/17/enabling-remote-debugging-via-private-apis-in-mobile-safari/" target="_blank">post</a> about it. With this solution we can enable a <strong>Remote Web Inspector on iOS Simulator</strong> included with Xcode 4.2 and iOS 5 SDK using some gdb (debugger) commands.</p>
<p>I&#8217;ve started this post as a tutorial on how to enable this option and debug webapps on the iOS Simulator. After writing this post, I&#8217;ve realized it was too difficult to use and enable for a typical web developer without Xcode experience.</p>
<p>My next thought was: &#8220;<em>it should be great to have a tool making these steps for us</em>&#8220;. And my saturday&#8217;s afternoon paid for that thought. I&#8217;d experience with Objective-C for iOS so it wasn&#8217;t difficult to create my first Cocoa Mac application using the same language. After a couple of hours, the first version of <a href="http://www.iwebinspector.com/" target="_blank">iWebInspector</a> was ready to go.</p>
<p><img class="alignnone" title="iWebInspector screenshot" src="http://www.iwebinspector.com/screenshot.png" alt="" width="640" height="338" /></p>
<p>The solution is not working -yet- on real iOS devices, just on the iOS Simulator -available only for Mac OS-. The tool can attach the Web Inspector to any tab opened in<strong> Safari for iOS</strong>, to a <strong>chrome-less webapp</strong> (full screen) or to a <strong>PhoneGap</strong> application -or any native application using <strong>UIWebView</strong>-.</p>
<h2>iWebInspector</h2>
<div>
<p>With this <a href="http://www.iwebinspector.com/" target="_blank">free tool</a> you can enable the full WebKit Web Inspector, including:</p>
<ul>
<li>See and browse every element on your HTML element. You can change attributes, content and styles and see how they apply on Safari</li>
<li>See all the resources involved in this page, including Databases, Local Storage, Cookies and ApplicationCache</li>
<li>Check all the network traffic on your website</li>
<li>See all your scripts, create breakpoints, watches and debug your JavaScript code.</li>
<li>Record a timeline showing you rendering, scripting and loading times while you browse on Safari</li>
<li>Profile your JavaScript code</li>
<li>Audit your code, showing you a report on performance and other stuff</li>
<li>See and use the JavaScript console</li>
</ul>
</div>
<p>I&#8217;m pretty sure that Apple will make this tool public in a future version of iOS.</p>
<h3><a href="http://www.iwebinspector.com/" target="_blank">Download iWebInspector</a></h3>
<h2></h2>
<h2>Attaching to PhoneGap and UIWebView</h2>
<p>If you are creating a PhoneGap application or a native iOS app with some UIWebView content, it&#8217;s easy to enable the Remote Web Inspector with a line of code instead of using <a href="http://www.iwebinspector.com/" target="_blank">iWebInspector</a>. This is a private API so remember to remove this line for the final compilation or you may have an AppStore rejection for private API usage.</p>
<p>Find your <strong>application:didFinishLaunchingWithOptions</strong> method on your <strong>AppDelegate.m</strong> file and add this line of code inside:</p>
<p><code>// Remove me after debugging<br />
[NSClassFromString(@"WebView") _enableRemoteInspector];<br />
</code></p>
<p>That&#8217;s all! After that, run your app on the simulator and <strong>localhost:9999</strong> will be pointing to the same Remote Web Inspector as in iWebInspector.</p>
<h2>Suggestions and Bug Report</h2>
<p>iWebInspector was created in a couple of hours, and this is the first version available.  If you find bugs, problems or if you have a suggestion, feel free to <a href="http://firt.mobi/" target="_blank">contact me</a> or leave a comment here.</p>
<p>&nbsp;</p>
<p>Enjoy!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.mobilexweb.com/blog/debugging-web-safari-phonegap-iphone-ipad/feed</wfw:commentRss>
		<slash:comments>16</slash:comments>
		</item>
		<item>
		<title>Android 4.0 Browser: smartphones meet tablets on HTML5 APIs</title>
		<link>http://www.mobilexweb.com/blog/android-4-0-browser-html5</link>
		<comments>http://www.mobilexweb.com/blog/android-4-0-browser-html5#comments</comments>
		<pubDate>Wed, 19 Oct 2011 11:44:19 +0000</pubDate>
		<dc:creator>firt</dc:creator>
				<category><![CDATA[New devices and browsers]]></category>
		<category><![CDATA[android]]></category>
		<category><![CDATA[html5]]></category>

		<guid isPermaLink="false">http://www.mobilexweb.com/?p=115</guid>
		<description><![CDATA[Tweet Android 4.0 was announced and the SDK was released. So, I&#8217;ve washed my hands, I&#8217;ve opened the emulator and I&#8217;ve started to dive into the new browser and see what&#8217;s in there and what&#8217;s not. Unfortunately it&#8217;s still Android Browser and not Chrome, but it comes in a better way. Busy month October 2011: [...]]]></description>
			<content:encoded><![CDATA[
	<div style="float: right; margin: 10px">
		<a href="http://twitter.com/share" class="twitter-share-button" data-count="horizontal" data-text="Android 4.0 Browser: smartphones meet tablets on HTML5 APIs - Mobile Web Programming" data-url="http://www.mobilexweb.com/blog/android-4-0-browser-html5"  data-via="mobilexweb @firt" data-related="firt:Blog\\\\\\\\\\\\\\\'s author">Tweet</a>
	</div>
	<script type="text/javascript" src="http://platform.twitter.com/widgets.js"></script><p>Android 4.0 was announced and the SDK was released. So, I&#8217;ve washed my hands, I&#8217;ve opened the emulator and I&#8217;ve started to dive into the new browser and see what&#8217;s in there and what&#8217;s not. Unfortunately it&#8217;s still Android Browser and not Chrome, but it comes in a better way.</p>
<p><span id="more-115"></span></p>
<h2>Busy month</h2>
<p>October 2011: Busy month for mobile web world.  Just a few days ago, I&#8217;ve blogged about <a href="http://www.mobilexweb.com/blog/ios-5-iphone-and-ipad-html5">Safari on iOS 5;</a> yesterday BlackBerry announced the first mobile browser with WebGL support on the (future) PlayBook platform and a few weeks ago Amazon announced Silk, a new proxy-based browser for tablets.</p>
<p>And now, it&#8217;s the Android turn. Android 4.0 was released and while there is no real phone yet to test it on (the <a href="http://www.google.com/nexus/" target="_blank">Galaxy Nexus</a> will be available soon) I&#8217;ve downloaded the emulator and I&#8217;ve tested the browser comparing it to Android 2.3 (smartphones) and Android 3.2 (tablet) that I both have on my hands.</p>
<p>Google announced that Google Chrome will be the future of browsing in Android but it was not 4.0 the time for that.</p>
<h2>Smartphones meets tablets</h2>
<p>This version merges both smartphones and tablets, so smartphones jumps from 2.3 to 4.0 acquiring all the new things on the browser available on 3.x, including:</p>
<ul>
<li>SVG</li>
<li>Motion Sensor API (accelerometer and gyroscope -on compatible devices-)</li>
<li>3D Transforms on CSS3</li>
<li>XHR 2 &amp; CORS</li>
<li>File API</li>
<li>HTML Media Capture API for camera/microphone access through file management</li>
<li>Binary Arrays (Int16Array, Float32Array, etc.)</li>
</ul>
<h2>What&#8217;s still missing on Android 4.0</h2>
<p>Unfortunately, there are still some missing APIs that are available on Google Chrome and on iOS5 -some of them-, including:</p>
<ul>
<li>No Server-sent events (BTW, does anybody use it?)</li>
<li>No WebSockets</li>
<li>No WebWorkers</li>
<li>No IndexedDB</li>
<li>No Web Notifications (that is a real shame for this platform &#8211; <a href="http://mobilehtml5.org/" target="_blank">Firefox on Android</a> is doing it-)</li>
<li>No WebGL</li>
<li>No History Management API</li>
<li>No rich input controls! I&#8217;ve found a huge bug on the range input type (no rendering at all), and no date controls are working. Even it seems that Android 3.x has better support than 4.x (more testing soon)</li>
</ul>
<h2>New stuff</h2>
<p>The new stuff for both smartphones and platforms I&#8217;ve found:</p>
<ul>
<li><a href="https://dvcs.w3.org/hg/webperf/raw-file/tip/specs/NavigationTiming/Overview.html" target="_blank">Navigation Timing API</a>, same API in IE9 on Windows Phone and in Firefox 7 for Android</li>
<li>New Console API, but not working properly, for example there is a console.memory.usedJSHeapSize and console.memory.totalJSHeapSize attributes, and some new functions but I could not make them work yet.</li>
<li>The HTML5 &lt;keygen&gt; new form is available</li>
<li>Basic MathML seems to work</li>
</ul>
<h2>New things to know</h2>
<div>The browser has new user features that can change the way our website will work.</div>
<div>
<ul>
<li>New Incognito Tab</li>
<li>New &#8220;Labs&#8221; section where the user can add full-screen webapp support on the browser and some gestures over the browser (similar to Firefox for Android)</li>
<li>New &#8220;Request Desktop site&#8221; feature that I&#8217;m not sure exactly everything it does, but it changes the User Agent at least.</li>
</ul>
<div>
<h2>Performance</h2>
</div>
<div>Android browser is well known as a problematic browser in terms of performance. Google in its <a href="http://developer.android.com/sdk/android-4.0.html" target="_blank">official documentation</a> claims to have a faster browser in 4.0 with an updated V8 JavaScript engine. The new engine shows a 35<a href="http://developer.android.com/sdk/android-4.0-highlights.html" target="_blank">-550% performance improvement </a>on different devices and tests according to Google. I can&#8217;t test it until have a real device with Android 4 installed.</div>
<div></div>
</div>
<p>&nbsp;</p>
]]></content:encoded>
			<wfw:commentRss>http://www.mobilexweb.com/blog/android-4-0-browser-html5/feed</wfw:commentRss>
		<slash:comments>15</slash:comments>
		</item>
		<item>
		<title>Safari on iOS 5, HTML5 evolution for iPhone and iPad</title>
		<link>http://www.mobilexweb.com/blog/ios-5-iphone-and-ipad-html5</link>
		<comments>http://www.mobilexweb.com/blog/ios-5-iphone-and-ipad-html5#comments</comments>
		<pubDate>Fri, 14 Oct 2011 13:11:37 +0000</pubDate>
		<dc:creator>firt</dc:creator>
				<category><![CDATA[New devices and browsers]]></category>

		<guid isPermaLink="false">http://www.mobilexweb.com/?p=95</guid>
		<description><![CDATA[Tweet It’s time again for a new version of iOS for iPhone and iPad and a bunch of news about mobile web development. I&#8217;ve analyzed every new feature I could found in Safari on iOS5, including what&#8217;s the final resolution with expected features as WebGL (3d) on Safari. Overview of new things HTML5 new APIs [...]]]></description>
			<content:encoded><![CDATA[
	<div style="float: right; margin: 10px">
		<a href="http://twitter.com/share" class="twitter-share-button" data-count="horizontal" data-text="Safari on iOS 5, HTML5 evolution for iPhone and iPad - Mobile Web Programming" data-url="http://www.mobilexweb.com/blog/ios-5-iphone-and-ipad-html5"  data-via="mobilexweb @firt" data-related="firt:Blog\\\\\\\\\\\\\\\'s author">Tweet</a>
	</div>
	<script type="text/javascript" src="http://platform.twitter.com/widgets.js"></script><p><a href="http://www.mobilexweb.com/wp-content/uploads/2011/10/ios5-logo1.png"><img class="alignleft size-thumbnail wp-image-105" style="margin: 5px;" title="ios5-logo1" src="http://www.mobilexweb.com/wp-content/uploads/2011/10/ios5-logo1-150x150.png" alt="" width="90" height="90" /></a>It’s time again for a new version of iOS for iPhone and iPad and a bunch of news about mobile web development. I&#8217;ve analyzed every new feature I could found in Safari on iOS5, including what&#8217;s the final resolution with expected features as WebGL (3d) on Safari.</p>
<p><span id="more-95"></span></p>
<h2>Overview of new things</h2>
<ul>
<li>HTML5 new APIs and feature support, including: Web Workers, Web History, new web form controls, inline SVG, MathML, Compass support, new external script attributes, some new CSS3 improvements and contenteditable</li>
<li>Fixed zones and scrolling areas support</li>
<li>New tabbed browsing for iPad but no desktop-like support</li>
<li>Performance improvements and Nitro engine on home screen webapps</li>
</ul>
<div>
<h2>First, the bad news</h2>
</div>
<div>
<p>As always, <strong>Apple is not giving us any useful information for its browser</strong>. Just to mention an example: in its change-log Apple only mentions that the new range input type is supported, while there are other new input types supported and not mentioned there. That&#8217;s why this post was done after a couple of hours researching over the new browser.</p>
</div>
<div>There are also some new features on iOS 5 that are out of developers&#8217; hands. So let&#8217;s first talk about bad news.</div>
<div>
<ul>
<li>There is a new <strong>notification center on iOS 5</strong> that allows native applications to notify the user using Push notification and Local notification mechanism. There is no way to participate in this notification area from Safari or a home screen webapp. Of course, we can use a hybrid or a PhoneGap HTML5 application to do so.</li>
<li><strong>Siri on iPhone 4S</strong>. This Star Trek-like voice assistant available on iPhone 4S uses the web as its source of information. However, there is no API or way today to communicate with Siri from our website to provide content or help it with our site.</li>
<li><strong>Twitter integration</strong>. The new iOS includes a Twitter integration inside the core of the operating system. However, there is no public API to access this Twitter registration information from our web application. That means that if the user is already logged in on Twitter using his device, it should log in again on our website with the classic Twitter web authorization API. Of course, we can still use the <a href="http://handleopenurl.com/scheme/twitter" target="_blank">Twitter URI schemes</a> if the application is installed to open the native Twitter client.</li>
</ul>
</div>
<h2>HTML5 news for iOS 5</h2>
<h3>HTML5 Elements</h3>
<p>Safari on iOS still doesn’t render anything special on the new elements <strong>progress</strong>, <strong>meter</strong>, <strong>detail</strong> and <strong>summary</strong>. If your web content is well and semantically designed, the new <strong>reader mode</strong> will be activated and your content will be converted into a &#8220;article mode&#8221; view if the user presses the reader button on the URL bar. There is no API or attributes to manage or customize reader mode. Create a good mobile web experience and your user will never use the reader mode :).</p>
<p><a href="http://www.mobilexweb.com/wp-content/uploads/2011/10/reader.png"><img class="alignnone size-full wp-image-107" title="reader" src="http://www.mobilexweb.com/wp-content/uploads/2011/10/reader.png" alt="" width="524" height="377" /></a></p>
<h3>Web Workers</h3>
<p>We can use workers to execute code in a different thread than the main UI thread using the <a href="http://dev.w3.org/html5/workers/" target="_blank">HTML5 Web Workers API</a>. This is great to provide good UI experiences when using lot of JavaScript execution.</p>
<h3>New Input types support</h3>
<p>iOS 5 supports new form rich controls using the input element, supporting <strong>range</strong> (rendered as a nice touch slider) and most date/time controls using <strong>date</strong>, <strong>time</strong>, <strong>datetime</strong>, <strong>month</strong> and <strong>datetime-local</strong>. From the HTML5 standard, color and week selector are still unsupported being rendered as plain text inputs. Datalist is still unsupported.</p>
<p>That is how this simple HTML elements are being rendered on iOS5 (iPhone and iPad):</p>
<p><code> &lt;input type="date"&gt;<br />
&lt;input type="datetime"&gt;<br />
&lt;input type="month"&gt;<br />
&lt;input type="range" min="0" max="40"&gt;</code></p>
<p><a href="http://www.mobilexweb.com/wp-content/uploads/2011/10/input.png"><img class="alignnone size-full wp-image-108" title="input" src="http://www.mobilexweb.com/wp-content/uploads/2011/10/input.png" alt="" width="400" height="359" /></a></p>
<h3>Inline SVG</h3>
<p>Now we can embed easily SVG graphics and animations using inline SVG, a new way to embed this kind of files inside an HTML using just a svg element, like que next example:<img class="alignright size-full wp-image-109" style="border-style: initial; border-color: initial;" title="inlinesvg" src="http://www.mobilexweb.com/wp-content/uploads/2011/10/inlinesvg.png" alt="" width="152" height="222" /></p>
<div>
<p><code> &lt;body&gt;<br />
&lt;svg xmlns="http://www.w3.org/2000/svg" version="1.1" width="300" height="100"&gt;<br />
&lt;rect x="0" y="0" width="100" height="100" style="fill:yellow" /&gt;<br />
&lt;circle cx="50" cy="50" r="30" style="fill:red" /&gt;<br />
&lt;/svg&gt;<br />
&lt;/body&gt;</code></p>
</div>
<h3>ClassList API</h3>
<p>Now we can use this new API on every DOM node using the classList attribute that provides different methods for class manipulation (a la jQuery) such as add, remove, toggle and contains. For example: <code>menuList.classList.add('touch');</code></p>
<h3>ContentEditable</h3>
<p>This new attribute, global to all the HTML5 elements, allows us to convert any HTML element into an editable one. That means that now a user can edit a list (ul element) or even we can create rich editors for iOS using <strong>contenteditable</strong> and <strong>execCommand</strong>. On my quick tests most visual rich editors for HTML are working properly on iOS5. Some of them are not optimized for touch, but in functionality, you can change formats and styles without any problem.</p>
<p>Here you have <a href="http://ckeditor.com/" target="_blank">CKEditor</a> working on iPad:</p>
<p><a href="http://www.mobilexweb.com/wp-content/uploads/2011/10/editor.png"><img class="alignnone size-full wp-image-111" title="editor" src="http://www.mobilexweb.com/wp-content/uploads/2011/10/editor.png" alt="" width="518" height="391" /></a></p>
<h3>History Management API</h3>
<p>Now we can change the URL without refreshing the page (and without using #) with this <a href="http://www.w3.org/TR/html5/history.html" target="_blank">new API inside HTML5 standard</a>. It exposes some new methods over the history object, such as <strong>pushState</strong>.</p>
<h3>Canvas</h3>
<p>Now it is hardware-accelerated as in Internet Explorer 9, so the performance is much more faster. <strong>CanvasPattern</strong> is now supported.</p>
<h3>Geolocation and iOS Simulator</h3>
<p>The iOS 5 Simulator for Mac now includes the ability to simulate different locations using latitude/longitude.</p>
<h3>MathML</h3>
<p>The markup language for math expressions is now available on iOS, so we can use the new math element in HTML and provide a MathML document inside. However, not every math special character is rendering propertly as I could check, such as Sum and big parentheses.</p>
<h3>XMLHttpRequest 2</h3>
<p><a href="http://www.w3.org/TR/XMLHttpRequest2/">XHR 2</a> is now supported but to be honest, it&#8217;s absolutely useless as file uploads and File API are disabled in Safari on iOS. The great advantage of XHR 2, the progress upload mechanism, is not allowed.</p>
<h3>LocalStorage</h3>
<p>Now it can be cleaned by the user in <em>Settings &gt; Safari</em> at the same time as cookies. The other new thing to keep in mind is that now a <strong>Private Browsing</strong> mode exists and we will receive exceptions if we try to use any offline API, such as LocalStorage, inside this mode. Keep in mind that you should catch this exceptions.</p>
<p>When activating Private Browsing Safari changes its whole UI to black:</p>
<p><a href="http://www.mobilexweb.com/wp-content/uploads/2011/10/private.png"><img class="alignnone size-full wp-image-112" title="private" src="http://www.mobilexweb.com/wp-content/uploads/2011/10/private.png" alt="" width="600" height="300" /></a></p>
<h3>Error handling</h3>
<p>Finally, <strong>window.onerror</strong> event is exposed so we can catch any JavaScript exception easily.</p>
<h3>DeviceMotion API</h3>
<p>Compass support is available in the devicemotion event through new attributes: <strong>webkitCompassHeading</strong> and <strong>webkitCompassAccuracy</strong>. There is also a new event we can subscribe to: <strong>compassneedscalibration</strong>. This will work only on iPad 2, iPhone 4, 4S and iPod touch last generation.</p>
<h3>Font Design</h3>
<p>Some CSS3 features were enhanced, such as support for <strong>:first-letter</strong> pseudo-element to have a different style for the first letter of a paragraph. Also <strong>text-rendering: optimizeLegibility</strong>; is now improving handling of kerning pairs and ligatures on typography. Now, <strong>WOFF</strong> (Web Open Font Format) is supported for CSS3 Web Fonts.</p>
<h3>New Gradient Syntax</h3>
<p>The new WebKit gradient syntax is supported, including: <code>-webkit-linear-gradient, -webkit-radial-gradient, -webkit-repeating-linear-gradient, -webkit-repeating-radial-gradient</code></p>
<h3>External script files</h3>
<p>Async scripts are now available using the <strong>async</strong> attribute. With asynchronic external script references, the script will be loaded without interfering with other resouces&#8217; downloads.</p>
<p><code>&lt;script src="external.js" async&gt;&lt;/script&gt;</code></p>
<p>It&#8217;s also available the <strong>defer</strong> attribute that allows the browser to defer the script execution until onload executes first.</p>
<p><code>&lt;script src="external.js" defer&gt;&lt;/script&gt;</code></p>
<h3><span class="Apple-style-span" style="font-size: 14px;">Sandboxed iframes</span></h3>
<h3><span class="Apple-style-span" style="font-size: 14px; font-weight: normal;">Now, an iframe can have different security implementations regarding the sandbox attribute as defined in this </span><a style="font-size: 14px; font-weight: normal;" href="http://www.whatwg.org/specs/web-apps/current-work/multipage/the-iframe-element.html#attr-iframe-sandbox" target="_blank">spec</a><span class="Apple-style-span" style="font-size: 14px; font-weight: normal;">.</span></h3>
<h3>Keep Waiting</h3>
<p>We still don’t have <strong>WebGL</strong> (3d canvas) even after demonstrating that WebGL is definitely there. It is deactivated and the rumor says that it’s there only for iAds usage inside a native app. We still don’t have <strong>IndexedDB</strong>, so Web SQL is the way to continue working with databases. And File Uploads or Camera APIs are also unsupported.</p>
<h2>Fixed Zones</h2>
<p>Finally, <strong>position: fixed</strong> is now working. This means that we can now leave those obscure tricks using touch events to emulate fixed toolbars and a lot of JavaScript code (equals CPU usage, equals battery consumption) for emulate momentum animation.</p>
<p>Keep in mind that when using <strong>position: fixed</strong> and a scalable viewport (or no viewport definition at all), the fixed zone zooms in/out as the viewport and it’s not really fixed as we could expect.</p>
<p>BTW, if you have a desktop website (not mobile-optimized) and fixed zones, you have a big problem! The fixed zones will create useless experiences when the user zooms in.</p>
<h2>Scrolling zones</h2>
<p>Before iOS 5 any scrolling zone, such as an element with <strong>overflow: scroll</strong> or an iframe had usability problems. That is because the user needs to use a two-finger scrolling gesture to scroll inside smaller areas in a page.</p>
<p>Now this problem has ended, as now <strong>every inner scrolling area will be scrolled using only one finger</strong>. And a new CSS extended attribute allows us to define what kinds of scrolling do we want: <strong>-webkit-overflow-scrolling</strong> that can accept <strong>auto</strong> (standard “desktop-like” scroll) or <strong>touch</strong> (with momentum, like native iOS applications or even like the page scroll momentum).</p>
<p><code> .scrollingWithMomentum {<br />
height: 200px;<br />
overflow: scroll;<br />
-webkit-overflow-scrolling: touch;<br />
}<br />
</code></p>
<h2>Tabs in iPad</h2>
<p>On iPad with iOS 5 we have now navigation using tabs. But be very careful! <strong>Tabs don’t work as in desktop</strong>. No tab will work in background or execute any background JavaScript and there is also no favicon support for the tab name. The user can now open a tab in background but your page will be live until onload and it will be frozen and reactivate when the user activate the tab.</p>
<p>If the browsers needs memory can release our page (even being already on an open tab) and when the user activates, the page will be reloaded. We can use sessionStorage to store information for this case.</p>
<h2>Performance and Nitro</h2>
<p>There is an excellent coverage of <a href="http://www.blaze.io/mobile/ios5-top10-performance-changes/" target="_blank">performance on iOS5 on Blaze.io blog</a>, so I will not get deeper in this topc. Performance on HTML5 is really improved, as well as some HTTP techniques for loading pages faster. After my testing I can now conclude that Nitro engine is now available on Home Screen apps and it’s still out of UIWebView (PhoneGap-like apps and pseudo-browsers such as SkyFire).</p>
<h2>Conclusion</h2>
<p>iOS 5 is in the line of HTML5 evolution but it still owe us some new features that are being added in other mobile browsers, such as WebGL, HTML Media Capture API, Device Network Information API and maybe a remote web inspector.</p>
<p>However, Safari on iOS is still the leader in terms of mobile browsers and it&#8217;s still the most important browser today to look at when developing mobile web experiences. However, <strong>be responsible and don&#8217;t create applications and websites that only works on Safari or WebKit</strong>.</p>
<p><em>What do you think? Are you happy with the new changes? Were you expecting more? Did you find anything else new? Feel free to use the comment area!</em></p>
]]></content:encoded>
			<wfw:commentRss>http://www.mobilexweb.com/blog/ios-5-iphone-and-ipad-html5/feed</wfw:commentRss>
		<slash:comments>22</slash:comments>
		</item>
		<item>
		<title>Presenting Mobile HTML5 compatibility tables</title>
		<link>http://www.mobilexweb.com/blog/presenting-mobile-html5-compatibility-table</link>
		<comments>http://www.mobilexweb.com/blog/presenting-mobile-html5-compatibility-table#comments</comments>
		<pubDate>Fri, 30 Sep 2011 21:20:46 +0000</pubDate>
		<dc:creator>firt</dc:creator>
				<category><![CDATA[General]]></category>

		<guid isPermaLink="false">http://www.mobilexweb.com/?p=92</guid>
		<description><![CDATA[Tweet September 2011 was a busy month for the mobile web space. While we are still waiting for iOS5, Android Ice cream sandwich, new mobile browsers appeared in the ecosystem: Internet Explorer 9 for Windows Phone 7.5, Firefox 7 for Android and the upcoming Amazon Silk to be included in the new Amazon Prime tablet. [...]]]></description>
			<content:encoded><![CDATA[
	<div style="float: right; margin: 10px">
		<a href="http://twitter.com/share" class="twitter-share-button" data-count="horizontal" data-text="Presenting Mobile HTML5 compatibility tables - Mobile Web Programming" data-url="http://www.mobilexweb.com/blog/presenting-mobile-html5-compatibility-table"  data-via="mobilexweb @firt" data-related="firt:Blog\\\\\\\\\\\\\\\'s author">Tweet</a>
	</div>
	<script type="text/javascript" src="http://platform.twitter.com/widgets.js"></script><p>September 2011 was a busy month for the mobile web space. While we are still waiting for iOS5, Android Ice cream sandwich, new mobile browsers appeared in the ecosystem: <strong>Internet Explorer 9</strong> for Windows Phone 7.5, <strong>Firefox 7</strong> for Android and the upcoming <strong>Amazon Silk</strong> to be included in the new Amazon Prime tablet.</p>
<p><span id="more-92"></span></p>
<p><img class="alignright size-full wp-image-93" title="logo_mobilehtml5" src="http://www.mobilexweb.com/wp-content/uploads/2011/09/logo_mobilehtml5.png" alt="" width="232" height="321" /></p>
<p>While the mobile space changes, there is one problem in the HTML5 world:<strong> the web community doesn&#8217;t fully <strong>understand the</strong> mobile world.</strong> That is why excellent resources such as <a href="http://www.modernizr.com" target="_blank">Modernizr</a> &amp; <a href="http://www.caniuse.com" target="_blank">Caniuse.com</a> don&#8217;t have accurate information about the mobile web space and web developers should not rely on that information.</p>
<p>HTML5 is on everybody&#8217;s mouth but web developers have a great challenge: understanding mobile web space and guessing if an HTML5 feature has enough compatibility in the market to start using and testing with it.</p>
<p>That is why, while I was presenting at the great <a href="http://www.bdconf.com" target="_blank">Breaking Development</a> conference in Nashville, I&#8217;ve announced a new project: <a href="http://www.mobilehtml5.org" target="_blank">MobileHTML5.org</a>.</p>
<p>Back in 2010 for my book <a href="book/" target="_blank">Programming the Mobile Web</a>, I&#8217;ve made a lot of testing over dozens of different mobile browsers. And that was the start for this new project.</p>
<p><img class="alignleft" style="margin-left: 5px; margin-right: 5px;" src="http://akamaicovers.oreilly.com/images/0636920021711/cat.gif" alt="" width="126" height="165" />And now I have a new big impulse for creating this site, a new upcoming book is now official: <a href="http://shop.oreilly.com/product/0636920021711.do" target="_blank">Mobile HTML5</a> to be published in early 2012 by O&#8217;Reilly Media, co-authored with <a href="http://standardista.com" target="_blank">Estelle Weyl</a>, a great partner for this new project.</p>
<p>So <a href="http://www.mobilehtml5.org" target="_blank">MobileHTML5.org</a> is the result of hours of testing over mobile browsers and I hope everyone can use and contribute to. This is just the start and I&#8217;m planning a bunch of new features for the following weeks, including: getting deeper in each API to understand differences between platforms; testing suites and code samples.</p>
<p>&nbsp;</p>
]]></content:encoded>
			<wfw:commentRss>http://www.mobilexweb.com/blog/presenting-mobile-html5-compatibility-table/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>jQuery Mobile workshop at #oscon</title>
		<link>http://www.mobilexweb.com/blog/jquery-mobile-workshop-at-oscon</link>
		<comments>http://www.mobilexweb.com/blog/jquery-mobile-workshop-at-oscon#comments</comments>
		<pubDate>Tue, 26 Jul 2011 15:30:50 +0000</pubDate>
		<dc:creator>firt</dc:creator>
				<category><![CDATA[General]]></category>

		<guid isPermaLink="false">http://www.mobilexweb.com/?p=89</guid>
		<description><![CDATA[Tweet On July, 26th I&#8217;m doing a workshop at OSCON about jQuery Mobile. If you are there (or not) here you can download the files we are going to use there. It&#8217;s algo a very good time to present my new book jQuery Mobile: Up and Running, available un Early Access. Download workshop files]]></description>
			<content:encoded><![CDATA[
	<div style="float: right; margin: 10px">
		<a href="http://twitter.com/share" class="twitter-share-button" data-count="horizontal" data-text="jQuery Mobile workshop at #oscon - Mobile Web Programming" data-url="http://www.mobilexweb.com/blog/jquery-mobile-workshop-at-oscon"  data-via="mobilexweb @firt" data-related="firt:Blog\\\\\\\\\\\\\\\'s author">Tweet</a>
	</div>
	<script type="text/javascript" src="http://platform.twitter.com/widgets.js"></script><p>On July, 26th I&#8217;m doing a workshop at OSCON about jQuery Mobile. If you are there (or not) here you can <a href="/workshop.zip">download the files</a> we are going to use there. It&#8217;s algo a very good time to present my new book <a href="/book">jQuery Mobile: Up and Running</a>, available un Early Access.</p>
<p><span id="more-89"></span></p>
<p><strong><a href="/workshop.zip">Download workshop files</a></strong></p>
]]></content:encoded>
			<wfw:commentRss>http://www.mobilexweb.com/blog/jquery-mobile-workshop-at-oscon/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Mobile Web &amp; HTML5 performance optimization</title>
		<link>http://www.mobilexweb.com/blog/mobile-web-html5-performance-optimization</link>
		<comments>http://www.mobilexweb.com/blog/mobile-web-html5-performance-optimization#comments</comments>
		<pubDate>Wed, 15 Jun 2011 16:15:27 +0000</pubDate>
		<dc:creator>firt</dc:creator>
				<category><![CDATA[Performance]]></category>
		<category><![CDATA[html5]]></category>
		<category><![CDATA[performance]]></category>
		<category><![CDATA[wpo]]></category>

		<guid isPermaLink="false">http://www.mobilexweb.com/?p=88</guid>
		<description><![CDATA[Tweet Velocity is an excellent annual conference organized by O&#8217;Reilly about web performance (WPO) and web operations. This was my second Velocity as speaker and I&#8217;m really surprised how bigger the show is this year. I did a workshop about mobile web &#38; html5 performance optimization and here you have my presentation. &#160; If you [...]]]></description>
			<content:encoded><![CDATA[
	<div style="float: right; margin: 10px">
		<a href="http://twitter.com/share" class="twitter-share-button" data-count="horizontal" data-text="Mobile Web & HTML5 performance optimization - Mobile Web Programming" data-url="http://www.mobilexweb.com/blog/mobile-web-html5-performance-optimization"  data-via="mobilexweb @firt" data-related="firt:Blog\\\\\\\\\\\\\\\'s author">Tweet</a>
	</div>
	<script type="text/javascript" src="http://platform.twitter.com/widgets.js"></script><p><img src="http://assets.en.oreilly.com/1/event/60/velocity2011_spkr_125x125.gif" width="125" height="125"  border="0"  alt="Velocity Conference 2011" title="Velocity Conference 2011"  align="left"  /><a href="http://www.velocityconf.com" target="_blank">Velocity</a> is an excellent annual conference organized by O&#8217;Reilly about web performance (WPO) and web operations. This was my second Velocity as speaker and I&#8217;m really surprised how bigger the show is this year. I did a workshop about mobile web &amp; html5 performance optimization and here you have my presentation.</p>
<p>&nbsp;</p>
<p><span id="more-88"></span>If you attended my workshop in Santa Clara, California and you have a feedback about it, please use the <a href="http://velocityconf.com/velocity2011/public/schedule/detail/19976" target="_blank">official workshop page</a> to give it. You can always comment here or send me an <a href="http://firt.mobi" target="_blank">e-mail</a>, of course. Thanks again to <a href="http://www.stevesouders.com" target="_blank">Steve Souders</a>, the guy behind WPO (Web Performance Optimization) and Velocity co-chair for inviting me again to this great conference.</p>
<p>Full video of my conference will be available later!</p>
<div style="width:425px" id="__ss_8316962"> <strong style="display:block;margin:12px 0 4px"><a href="http://www.slideshare.net/firt/mobile-web-html5-performance-optimization" title="Mobile Web &amp; HTML5 Performance Optimization">Mobile Web &amp; HTML5 Performance Optimization</a></strong> <iframe src="http://www.slideshare.net/slideshow/embed_code/8316962" width="625" height="455" frameborder="0" marginwidth="0" marginheight="0" scrolling="no"></iframe>
<div style="padding:5px 0 12px"> View more <a href="http://www.slideshare.net/">presentations</a> from <a href="http://www.slideshare.net/firt">Maximiliano Firtman</a> </div>
</p></div>
<p>&nbsp;</p>
]]></content:encoded>
			<wfw:commentRss>http://www.mobilexweb.com/blog/mobile-web-html5-performance-optimization/feed</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>HTML5 and new features in Safari for iOS 5 beta 1</title>
		<link>http://www.mobilexweb.com/blog/html5-safari-ios5-beta</link>
		<comments>http://www.mobilexweb.com/blog/html5-safari-ios5-beta#comments</comments>
		<pubDate>Fri, 10 Jun 2011 15:36:54 +0000</pubDate>
		<dc:creator>firt</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[New devices and browsers]]></category>
		<category><![CDATA[html5]]></category>
		<category><![CDATA[ios]]></category>
		<category><![CDATA[ios5]]></category>
		<category><![CDATA[safari]]></category>

		<guid isPermaLink="false">http://www.mobilexweb.com/?p=82</guid>
		<description><![CDATA[Tweet As you may already known, iOS 5 beta 1 was released for registered developers and there was a presentation showing some of the new features in Safari. I’ve made the usual investigation to see what’s new and I find a way to show you what&#8217;s new in HTML5. UPDATE: Final version of iOS5 is [...]]]></description>
			<content:encoded><![CDATA[
	<div style="float: right; margin: 10px">
		<a href="http://twitter.com/share" class="twitter-share-button" data-count="horizontal" data-text="HTML5 and new features in Safari for iOS 5 beta 1 - Mobile Web Programming" data-url="http://www.mobilexweb.com/blog/html5-safari-ios5-beta"  data-via="mobilexweb @firt" data-related="firt:Blog\\\\\\\\\\\\\\\'s author">Tweet</a>
	</div>
	<script type="text/javascript" src="http://platform.twitter.com/widgets.js"></script><p><img class="alignleft" style="margin-left: 5px; margin-right: 5px;" src="http://www.mobilexweb.com/wp-content/uploads/2011/06/ios52.png" alt="" width="71" height="72" />As you may already known, iOS 5 beta 1 was released for registered developers and there was a presentation showing some of the new features in Safari. I’ve made the usual investigation to see what’s new and I find a way to show you what&#8217;s new in HTML5.</p>
<div>
<p><span id="more-82"></span></p>
<p><strong>UPDATE: Final version of iOS5 is available. Here you have the <a href="http://www.mobilexweb.com/blog/ios-5-iphone-and-ipad-html5">updated post</a>.</strong></p>
<p>&nbsp;</p>
<p>Since iOS 2, Safari is the mobile browser with most surprises on every version of the O.S. There are one problem with that: new features are never documented on time by Apple. So we need to figure out new things by ourselves. Some things are easy to discover and some others are nearly impossible (such as new meta tags).</p>
<h2>Wishes</h2>
<p>After iOS 4.3, lot of things were discussed on blogs and discussion forums about features (and lack of) and a lot of wishes lists were published, including:</p>
</div>
<div>
<ul>
<li>WebGL (aka 3D Drawing API)</li>
<li>Web Workers</li>
<li>Nitro support on full-screen webapps and hybrids (see this post for more info)</li>
<li>HTML5 no working form input types (such as date, datetime, etc.)</li>
<li>Position: fixed support</li>
<li>File upload support</li>
<li>Background / widget support</li>
<li>Notificacions API</li>
<li>Document inspector support</li>
</ul>
<p>Most of these missing features on iOS are available right now on <a href="http://www.mobilexweb.com/blog/blackberry-playbook-tablet-browser-html5" target="_blank">BlackBerry Browser for PlayBook</a>, so it was expected that the next version of iOS should add some of them. I’ve tested it for some days and I’ve my conclusions for Beta 1. These conclusions are not final, as things can change until the final version is published.</p>
<h2>My findings</h2>
<p>I have one bad news and one good news. The bad one: I can not publish my conclusions here, because Apple has every aspect of iOS 5 SDK under <strong>NDA</strong> (Non-Disclosure Agreement); so <strong><em>I can’t talk about it in public</em>.</strong> The good one: If you are also under NDA (you are an approved iOS Developer), you can continue reading and discussing my full post <strong><a href="https://devforums.apple.com/thread/103973" target="_blank">here &gt;&gt;&gt;&gt;</a></strong>.</p>
<h2>What’s new (public information)</h2>
<p><img class="alignnone" src="http://images.apple.com/ios/ios5/images/features_safari_overview.png" alt="" width="617" height="330" /> What I can tell you here is the public information about Safari and iOS 5. It is announced as a faster browser experience (without technical information) with tab support on iPad (finally!) and two new features borrowed from Safari on Desktop:</p>
<ul>
<li><strong>Reading List</strong>: a feature that mixed with iCloud let you mark a webpage for future reading while this list is synchronized between all your devices (including desktop).</li>
<li><strong>Safari Reader</strong>: a new mode that will let the user read the current article without distractions (it removes ads, logos and it changes the CSS style of your site). This is similar to Safari on Desktop and to Readability</li>
</ul>
<p>Tabs appears without any icon (as we are used to in desktop). Twitter is also integrated inside Safari so the Actions buttons now has new options as you can see in the image below: <img class="alignnone" src="http://images.apple.com/ios/ios5/images/features_safari_readinglist.png" alt="" width="647" height="345" /></p>
<p>iOS 5 has now a Notification Center (very similar to Android’s one), but there is no public information about usage from a webpage. If you want to read the <strong><a href="https://devforums.apple.com/thread/103973" target="_blank">full post (under NDA)</a></strong> with the new stuff for HTML5, go to <strong><a href="https://devforums.apple.com/thread/103973" target="_blank">this link</a></strong>.</p>
</div>
]]></content:encoded>
			<wfw:commentRss>http://www.mobilexweb.com/blog/html5-safari-ios5-beta/feed</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
		<item>
		<title>Symbian Anna Browser &amp; HTML5: is it the evolution expected?</title>
		<link>http://www.mobilexweb.com/blog/symbian-anna-browser-html5</link>
		<comments>http://www.mobilexweb.com/blog/symbian-anna-browser-html5#comments</comments>
		<pubDate>Thu, 14 Apr 2011 00:06:30 +0000</pubDate>
		<dc:creator>firt</dc:creator>
				<category><![CDATA[New devices and browsers]]></category>
		<category><![CDATA[html5]]></category>
		<category><![CDATA[nokia]]></category>
		<category><![CDATA[symbian]]></category>

		<guid isPermaLink="false">http://www.mobilexweb.com/?p=75</guid>
		<description><![CDATA[Tweet Nokia has just announced Symbian &#8216;Anna&#8217;, an updated version of Symbian^3 that will be shipped with new devices, such as X7 and E6, and will be available as an OTA update for other devices, such as N8 and E7. I&#8217;ve the opportunity to test the new updated browser and here are the results. As [...]]]></description>
			<content:encoded><![CDATA[
	<div style="float: right; margin: 10px">
		<a href="http://twitter.com/share" class="twitter-share-button" data-count="horizontal" data-text="Symbian Anna Browser & HTML5: is it the evolution expected? - Mobile Web Programming" data-url="http://www.mobilexweb.com/blog/symbian-anna-browser-html5"  data-via="mobilexweb @firt" data-related="firt:Blog\\\\\\\\\\\\\\\'s author">Tweet</a>
	</div>
	<script type="text/javascript" src="http://platform.twitter.com/widgets.js"></script><p>Nokia has just announced <a href="http://events.nokia.com/discover-symbian/" target="_blank">Symbian &#8216;Anna&#8217;</a>, an <strong>updated version of Symbian^3</strong> that will be shipped with new devices, such as X7 and E6, and will be available as an OTA update for other devices, such as N8 and E7. I&#8217;ve the opportunity to test the new updated browser and here are the results.</p>
<p><span id="more-75"></span><a href="http://www.mobilexweb.com/wp-content/uploads/2011/04/Nokia-X7-00_001.png"><img class="alignnone size-full wp-image-78" title="Nokia X7-00_001" src="http://www.mobilexweb.com/wp-content/uploads/2011/04/Nokia-X7-00_001.png" alt="" width="512" height="288" /></a></p>
<p>As you may know, Symbian is one of the main smartphone platforms out there. Of course, if you live in the US you may think I&#8217;m crazy. Outside US, Symbian still has a great amount of devices available and even with the future Windows Phone replacement, dozens of millons of Symbian devices are going to be sold in the next two years.</p>
<p>I&#8217;ve tested a <a href="https://www.forum.nokia.com/Devices/Device_specifications/X7-00/" target="_blank">Nokia X7-00</a> prototype device with the final version of the new <a href="http://events.nokia.com/discover-symbian/" target="_blank">Symbian Anna</a>. If we see the website, &#8220;the new browser&#8221; is one of the key features. It&#8217;s funny to see that the announcement was done the same day as Microsoft showing the Internet Explorer 9 future browser for Windows Phone.</p>
<p>Symbian browser, as mentioned in <a href="/book" target="_blank">my book</a>, has a lot of history. It was one of the first mobile browser using WebKit as its engine. However, since devices like Nokia N95 (shipped before iPhone arrives to the market), the browser has not evolve as fast as developers wanted. It was WebKit, but it was far away in terms of standards supports if we compare it with Safari on iOS, Android Browser or other WebKit-based mobile engines.</p>
<p><strong>You are waiting for my veredict</strong>, I know. Well&#8230; honestly, I was expecting more. The browser is much faster than before, but <strong>it still feels old</strong> compared to other smartphone&#8217;s browsers.</p>
<p>Here you can see what <a href="http://www.modernizr.com" target="_blank">Modernizr</a> has to say about this browser:</p>
<p><a href="http://www.mobilexweb.com/wp-content/uploads/2011/04/Nokia-X7-00.png"><img class="alignnone size-full wp-image-79" title="Nokia X7-00" src="http://www.mobilexweb.com/wp-content/uploads/2011/04/Nokia-X7-00.png" alt="" width="360" height="640" /></a></p>
<p>The features detected by Modernizr have some mistakes. For example, it does support SVG.</p>
<h2>The new stuff</h2>
<p>The key new features are <strong>enhanced CSS3 support </strong>and<strong> multi-window browsing</strong>. Without taking performance on the test, the Symbian Anna Browser add support for mostly every CSS3 feature on WebKit browsers, such as Android, iOS and webOS including:</p>
<ul>
<li><strong>Gradients</strong></li>
<li><strong>Transformations</strong> 2D</li>
<li><strong>Transitions</strong></li>
<li><strong>Animations</strong></li>
<li><strong>Media Queries</strong></li>
</ul>
<p>&nbsp;</p>
<p>Talking about APIs and Graphic drawing, it supports:</p>
<ul>
<li><strong>Canvas</strong> &#8211; 2D drawing API</li>
<li><strong>SVG</strong> (it was supported before)</li>
</ul>
<p>The browser seems much faster than the previous version but it&#8217;s difficult to have an exact measure because I couldn&#8217;t test it yet on the same device.</p>
<h2>HTML5, are you there?</h2>
<p>We know that HTML5 is not a simple concept. It&#8217;s an umbrella for many, many different things. However, every browser shipped in 2011 needs to be HTML5-some-kind-compatible.</p>
<p>I can&#8217;t believe that a mobile browser released this year can be shipped without W3C Geolocation API support. It&#8217;s a basic API, a more mature standard than HTML5 and very simple to implement. So: <strong>Symbian Anna Browser does not support Geolocation</strong>.</p>
<p>In fact, <strong>it doesn&#8217;t support any HTML5 API apart from Canvas</strong> (2D drawing). Other great missing is <strong>video &amp; audio</strong> support. You can still use <strong>Flash</strong> for video playing on Symbian browser, but video tag was a feature I was expecting for this release.</p>
<p>What is <strong>missing </strong>from the main HTML5 features available on other platforms:</p>
<ul>
<li>No Viewport support</li>
<li>No Audio &amp; Video tag support (the multimedia events seems to be there, but I couldn&#8217;t see a &lt;video&gt; tag working)</li>
<li>No Application Cache / Offline storage mechanisms</li>
<li>No Geolocation API</li>
<li>No Accelerometer / Motion API</li>
<li>No HTML5 new input types (even when Modernizr says &#8216;supported&#8217;, every input type uses the same text input with the same on-screen keyboard)</li>
</ul>
<p>We can still access most of these features from the <strong>WRT widget platform</strong> (<a href="/book" target="_blank">see Chapter 12</a>). In fact, Symbian is one of the main platform supporting Home Screen widgets created entirely from HTML, CSS &amp; JavaScript. But the lack of these features from the browser environment makes me feel strange about this new browser.</p>
<p><strong>I believe Nokia has work to do in the next two years for the Symbian Browser.</strong> I hope a new update later this year will add more compatibility. BTW, I&#8217;m a <a href="https://www.forum.nokia.com/Community/Champions/" target="_blank">Forum Nokia Champion</a> and I have a lot of Nokia devices on my pocket&#8217;s history ;).</p>
]]></content:encoded>
			<wfw:commentRss>http://www.mobilexweb.com/blog/symbian-anna-browser-html5/feed</wfw:commentRss>
		<slash:comments>30</slash:comments>
		</item>
		<item>
		<title>Is Apple trying to hinder PhoneGap and other HTML5 frameworks with iOS 4.3?</title>
		<link>http://www.mobilexweb.com/blog/apple-phonegap-html5-nitro</link>
		<comments>http://www.mobilexweb.com/blog/apple-phonegap-html5-nitro#comments</comments>
		<pubDate>Mon, 14 Mar 2011 19:46:35 +0000</pubDate>
		<dc:creator>firt</dc:creator>
				<category><![CDATA[General]]></category>

		<guid isPermaLink="false">http://www.mobilexweb.com/?p=71</guid>
		<description><![CDATA[Tweet Last week Apple released iOS 4.3 and the new Nitro engine was presented inside Safari on iOS for iPhone, iPod Touch and iPad. The iPad 2 with iOS 4.3 is on its way in US and worldwide in next days. However, a new situation was discovered last days alarming a lot of developers: Nitro [...]]]></description>
			<content:encoded><![CDATA[
	<div style="float: right; margin: 10px">
		<a href="http://twitter.com/share" class="twitter-share-button" data-count="horizontal" data-text="Is Apple trying to hinder PhoneGap and other HTML5 frameworks with iOS 4.3? - Mobile Web Programming" data-url="http://www.mobilexweb.com/blog/apple-phonegap-html5-nitro"  data-via="mobilexweb @firt" data-related="firt:Blog\\\\\\\\\\\\\\\'s author">Tweet</a>
	</div>
	<script type="text/javascript" src="http://platform.twitter.com/widgets.js"></script><p>Last week Apple released iOS 4.3 and the new Nitro engine was presented inside Safari on iOS for iPhone, iPod Touch and iPad. The iPad 2 with iOS 4.3 is on its way in US and worldwide in next days. However, a new situation was discovered last days alarming a lot of developers: <strong>Nitro is not available for PhoneGap and other webapp-related solutions</strong>. Is it a deliberate attempt to hinder PhoneGap and other HTML5 frameworks?</p>
<p><span id="more-71"></span></p>
<p>After <a href="http://www.twitter.com/firt">my tweets</a> last Saturday about this limitations, I&#8217;ve received dozens of contacts (e-mails, tweets, contacts from the press) asking me about why Apple is doing this. First, let&#8217;s see what is the problem and let&#8217;s analyze it later.</p>
<p><em>ALERT: If you are in a hurry and don&#8217;t want to read the whole post, the answer is <strong>NO</strong>. I don&#8217;t believe it is a deliberate attempt to hinder HTML5/hybrid frameworks</em>. <em>If you want to know why, then read the post.</em></p>
<h2>Nitro engine</h2>
<p>As I showed on my last <a href="http://www.mobilexweb.com/blog/safari-ipad-iphone-4-3" target="_blank">post about iOS 4.3 new stuff</a>, Nitro engine provides a 2x performance increase in JavaScript inside Safari on iOS for iPhone and iPad. It is good for HTML5 webapps, mostly using heavy JavaScript code, and for frameworks, like <strong>jQuery Mobile</strong>, <strong>Sencha Touch</strong> and many others.</p>
<p>Everyone (myself included) thought: &#8220;if Nitro is available in Safari, it will be available also on other places where we normally execute JavaScript&#8221;. And that is <strong>wrong</strong>. Right now (iOS 4.3), <strong>the Nitro engine only works inside Safari</strong>: a webpage based on a URL with the full Safari UI loaded.</p>
<h2>Nitro on UIWebView</h2>
<p>I&#8217;ve started making other tests and I&#8217;ve found (like many others on Twitter) that Nitro seems to be disabled on UIWebView. <strong>UIWebView</strong> is a native control inside UIKit, one of the frameworks inside iOS SDK for native development. It provides a <strong>WebKit engine</strong> inside a native app. In fact, because of the iOS Developer Agreement, UIWebView is the only accepted web runtime for a native app. That is why there is not a Firefox for iOS (Opera Mini is a different thing).</p>
<p>The UIWebView control is useful in many cases, including:</p>
<ul>
<li>Apps showing <strong>HTML5 content</strong> inside, such as magazines and newspapers.</li>
<li>Apps with a <strong>quick web browsing feature</strong>, such as Twitter for iPad when you click on a link.</li>
<li>&#8220;<strong>Browser apps</strong>&#8220;. I like to call them &#8220;pseudo-browsers&#8221;. They are on AppStore and publicite themselves as browsers, but they are just the same Safari engine on steroids, providing some additional feature (such as tab navigation). One example of a pseudo-browser is <a href="http://skyfire.com/" target="_blank">SkyFire</a>.</li>
<li><strong>PhoneGap</strong> and other Full-HTML5 <strong>hybrid apps</strong>. This kind of projects are just a full-screen UIWebView loading some web content inside.</li>
</ul>
<p>Right now, <strong>Nitro is not available</strong>. Here you will find two screenshots: one from a native app with a UIWebView I&#8217;ve created in two minutes; the other is just SkyFire for iPad. On the SunSpider benchmark test, using the same iPad as in <a href="http://www.mobilexweb.com/blog/safari-ipad-iphone-4-3" target="_blank">this post</a>, I&#8217;ve received similar results as in iOS 4.2: <strong>no Nitro engine on UIWebView</strong>. Remember, in Safari for iOS 4.3 the results were <strong>3.5 seconds</strong>.</p>
<p><em>UPDATE: A lot of discussion is going on in Twitter. Right now, the theory about why Nitro is not on UIWebView is because of a security and kernel problem. Here you will find more <a href="http://news.ycombinator.com/item?id=2318028" target="_blank">information</a>. Nitro is a JIT (just in time) compiler, and that can lead to security issues (JavaScript code that could potentially execute non-secure native code) and there are some problems with memory management also for JIT to work. However, this theory leads to other question: <strong>is then Safari for iOS 4.3 with Nitro secure enough</strong>? If this is true, maybe an official response will clarify and calm down some developers ;)</em></p>
<p><a href="http://www.mobilexweb.com/wp-content/uploads/2011/03/ios4-3-nitro2.png"><img class="alignnone size-large wp-image-72" title="Benchmark using UIWebKit on a custom app (left) and on SkyFire (right) using both iOS 4.3" src="http://www.mobilexweb.com/wp-content/uploads/2011/03/ios4-3-nitro2-1024x605.png" alt="" width="614" height="363" /></a></p>
<h2>Nitro on full-screen webapps</h2>
<p>Safari on iOS has an excellent feature that I still can&#8217;t believe Android, Nokia or BlackBerry doesn&#8217;t support yet. Using just some HTML and some JavaScript, (as discussed on <a href="/book">Chapter 9</a>) you can suggest, or even force, a user to add the app to the <strong>Home Screen</strong>. When done, the user will receive an icon inside the home menu as any other native app installed. Using a second meta tag (<strong>apple-mobile-web-app-capable</strong>) you can force your webapp to be opened in full-screen mode.</p>
<p>Well, <strong>a webapp opened in full-screen mode does not use Nitro engine</strong> (again, this is not a native app, just an HTML with a shortcut from Safari). Here is the test that you can do it yourself at <strong><a href="http://ad.ag/pjmamj" target="_blank">http://ad.ag/pjmamj</a></strong> using an iOS 4.3 device.</p>
<p>Here you will find two results using an iPod Touch 4G with the exactly same HTML file: one using the classic Safari UI (result: 4.2 seconds) and other after install an icon on the Home Screen and opened in full-screen mode (result: 10.2 seconds).</p>
<p><a href="http://www.mobilexweb.com/wp-content/uploads/2011/03/ios4-3-nitro3.png"><img class="alignnone size-large wp-image-73" title="The same HTML file running in Safari standard mode and in full-screen mode on iPod Touch 4.3" src="http://www.mobilexweb.com/wp-content/uploads/2011/03/ios4-3-nitro3-1024x655.png" alt="" width="614" height="393" /></a></p>
<h2>Is this a deliberate attempt from Apple?</h2>
<p>This is a big question. I&#8217;m seeing a lot of angry people out there. I&#8217;m seeing a lot of conspiracy theories about this. <strong>I don&#8217;t believe this is a deliberate attempt from Apple</strong>. I can&#8217;t be 100% sure because I don&#8217;t work at Apple, but I&#8217;m not seeing any excuse to do that. I believe it&#8217;s more a &#8220;missing feature&#8221;, a security problem, an AppStore Rules problem, or maybe a bug.</p>
<p>First of all, does this problem mean that PhoneGap apps or SkyFire doesn&#8217;t work anymore? No, they just work as in iOS 4.2 (and I believe everyone was happy with that, a month ago). Ok, I know&#8230; it&#8217;s a shame that Nitro is not available there. Yes, it&#8217;s a shame and I really hope to have this included in a future release (maybe 4.3.1, 4.4 or 5) but I believe that it doesn&#8217;t worth new conspiracy theories.</p>
<h2>UIWebView vs Safari</h2>
<p>One guy from Apple commented me in an informal chat that the engine behind UIWebView and Safari is the same one. However, he also confirmed me that <strong>Safari IS NOT using UIWebView inside</strong>. That is, they share the same engine but they are two different things inside the O.S. So, technically they can work different without any conspiracy theory. Therefore,<strong> UIWebView is not a Safari loaded inside an app</strong>.</p>
<p>And it&#8217;s also possible that when a full-screen webapp is opened, it is done using UIWebView and not Safari. Because the Safari UI is hidden, why use the full Safari controls if they can do it with just UIWebView?<strong> This is just my guess on why Nitro is not available on full-screen webapps</strong>. I&#8217;m not completely sure but it makes sense to me.</p>
<p><em>UPDATE: Some guys told me that apparently a full-screen webapp is using an internal process called WebSheet.app</em></p>
<p><em>It can be deliberate, it can be because of a bug or it can be because they forgot about it, I don&#8217;t know. I&#8217;m trying not being naive</em> about this, but this is not the first time I see bugs around UIWebView or full-screen webapps on a big change (I remember a lot of bugs in iOS 4.0). Maybe it&#8217;s not a priority inside internal Apple testings.</p>
<h2>What to do?</h2>
<p>Unfortunately, Safari on iOS and even UIWebView without Nitro, are the most powerful mobile HTML5 engines out there. I say &#8220;unfortunately&#8221;, because I want Android, BlackBerry, Nokia, HP to reach Apple&#8217;s engine. Some are close, but Apple is still ahead.</p>
<p>Even if we talk about full-screen webapps: <strong>Apple is the only platform supporting this feature</strong>.</p>
<p>You can love or hate Apple, but you can&#8217;t ignore that it is the best WebKit engine out there in the mobile space. Therefore, <strong>why do something against it?</strong></p>
<p>I can not believe today in Steve Jobs saying: &#8220;let&#8217;s remove PhoneGap from the equation&#8221;. (I&#8217;m using PhoneGap just as a sample: it can be anyone on the HTML5 webapp side). I&#8217;m not seeing how PhoneGap can hurt Apple today. I&#8217;m not seeing any political issue like in Apple-Adobe. And I&#8217;m not seeing that the lack of Nitro is hurting PhoneGap apps directly right now. It&#8217;d be better to have it, but right now it&#8217;s not the worst thing in the world; it&#8217;s still the best platform for this kind of projects.</p>
<p>In my opinion we need to wait until next release and in the meantime, use the <strong><a href="https://bugreport.apple.com/" target="_blank">Bug Request Form</a></strong> to submit our opinion and suggestions for next versions.</p>
<p>What do you think?</p>
]]></content:encoded>
			<wfw:commentRss>http://www.mobilexweb.com/blog/apple-phonegap-html5-nitro/feed</wfw:commentRss>
		<slash:comments>14</slash:comments>
		</item>
		<item>
		<title>What&#8217;s new on Safari for iPhone 4.3 and iPad 4.3</title>
		<link>http://www.mobilexweb.com/blog/safari-ipad-iphone-4-3</link>
		<comments>http://www.mobilexweb.com/blog/safari-ipad-iphone-4-3#comments</comments>
		<pubDate>Thu, 10 Mar 2011 13:17:42 +0000</pubDate>
		<dc:creator>firt</dc:creator>
				<category><![CDATA[General]]></category>

		<guid isPermaLink="false">http://www.mobilexweb.com/?p=65</guid>
		<description><![CDATA[Tweet Once more, we have an iOS update for iPhone, iPod and iPad: version 4.3. And like previous versions, I was playing with Safari, the native browser, to see what&#8217;s new for web designers and developers. And here are the results. Last version (4.2) gave us new HTML5 stuff, like DeviceMotion API for accelerometer support [...]]]></description>
			<content:encoded><![CDATA[
	<div style="float: right; margin: 10px">
		<a href="http://twitter.com/share" class="twitter-share-button" data-count="horizontal" data-text="What's new on Safari for iPhone 4.3 and iPad 4.3 - Mobile Web Programming" data-url="http://www.mobilexweb.com/blog/safari-ipad-iphone-4-3"  data-via="mobilexweb @firt" data-related="firt:Blog\\\\\\\\\\\\\\\'s author">Tweet</a>
	</div>
	<script type="text/javascript" src="http://platform.twitter.com/widgets.js"></script><p>Once more, we have an iOS update for iPhone, iPod and iPad: version 4.3. And like previous versions, I was playing with Safari, the native browser, to see what&#8217;s new for web designers and developers. And here are the results.</p>
<p><span id="more-65"></span></p>
<p>Last version (4.2) gave us <a href="http://www.mobilexweb.com/blog/safari-ios-accelerometer-websockets-html5" target="_blank">new HTML5 stuff</a>, like DeviceMotion API for accelerometer support and WebSockets for full-duplex server-client communication.</p>
<p><strong>This version doesn&#8217;t give us big changes or new APIs. </strong>However, there are some minor (and core) changes to talk about it.</p>
<p><strong>There is still no support for file uploads, Web Workers or WebGL</strong>. WebGL (3D canvas) seems to be there in the DOM with the WebGLRenderingContext constructor. However, I couldn&#8217;t find any way to initiate the WebGL engine, so I&#8217;m pretty sure it is currently disabled by Apple.</p>
<h2>Performance on Nitro</h2>
<p>Safari gets its first big change at core level: a <strong>new JavaScript engine </strong>called<strong> Nitro</strong>. It is transparent for us, there is nothing new to do for having support for this new engine. With Nitro Apple claimed to improve JavaScript performance  up to twice as fast as in previous version.</p>
<p><em>UPDATE: Nitro engine seems to be available only in Safari (the browser) and not by embedding a UIWebView inside a native app, like in a hybrid app such as PhoneGap app or using any pseudo-browser, such as SkyFire. At least, in my tests this happens with every app compiled for 4.2 and for 4.3.</em></p>
<p><em>UPDATE #2: Nitro engine is also disabled on full-screen webapps added to the Home Screen. That is, not native webapps, using the <strong>apple-mobile-web-app-capable</strong> meta tag.</em></p>
<p>I&#8217;ve tested it using <a href="http://www.webkit.org/perf/sunspider/sunspider.html">Sun Spider JavaScript Benchmark tool</a> using the same iPad 3G with 4.2.1 and 4.3. The results seems promising: 8.2 seconds in iOS 4.2 vs. 3.4 seconds in iOS 4.3. That is near a <strong>2.5X performance improvement!</strong>.</p>
<div id="attachment_66" class="wp-caption alignnone" style="width: 624px"><a href="http://www.mobilexweb.com/wp-content/uploads/2011/03/ios4.3.png"><img class="size-large wp-image-66 " title="SunSpider running on the same iPad with 4.2 and 4.3" src="http://www.mobilexweb.com/wp-content/uploads/2011/03/ios4.3-1024x524.png" alt="" width="614" height="314" /></a><p class="wp-caption-text">SunSpider running on the same iPad with 4.2 and 4.3</p></div>
<p>I&#8217;m not the only one doing this benchmarks, look at this <a href="http://www.zdnet.com/blog/hardware/ios-43-safari-javascript-engine-benchmarked/11807" target="_blank">ZDNet Article</a>.</p>
<h2>HTML5 video and AppleTV</h2>
<p>This version of the OS supports <strong>AirPlay</strong>, that is the ability to stream multimedia content to our TV through <a href="http://www.apple.com/appletv">AppleTV</a>. Our HTML5 content can also make use of this ability through a new attribute applied to the video tag: <strong>x-webkit-airplay</strong> with value &#8220;<strong>allow&#8221;</strong>, for example:</p>
<pre>&lt;video src="" x-webkit-airplay="allow"&gt;&lt;/video&gt;</pre>
<p>When this attribute is there and you actually have an Apple TV (with an updated firmware), the player will show a new icon over the video player to start the streaming. The attribute also supports the value &#8220;<strong>deny&#8221;</strong>, acting as the default value for the player. This attribute also works for the non-HTML5 <strong>embed</strong> tag. I&#8217;m not really sure why it is denied by default as this seems to be an useful feature if you have an Apple TV for all videos.</p>
<p>This is how the player looks when streaming the video to the TV:</p>
<p><a href="http://www.mobilexweb.com/wp-content/uploads/2011/03/appletv.png"><img class="alignnone size-full wp-image-67" title="appletv" src="http://www.mobilexweb.com/wp-content/uploads/2011/03/appletv.png" alt="" width="434" height="244" /></a></p>
<h2>CSS Variables</h2>
<p>On the CSS side, Safari for iOS 4.2 made available in the DOM the <strong><a href="http://disruptive-innovations.com/zoo/cssvariables/" target="_blank">variable rule</a></strong> (had anyone notice it?). A variable rule is a non-standard way to declare variable values in CSS (pretty cool!). But I couldn&#8217;t make it work on real code. <strong>Don&#8217;t get too excited about it: </strong>the support for this feature was finally removed in iOS 4.3.</p>
<p>The <strong>CSSRule</strong> is a JavaScript interface available in WebKit that shows every CSS rule available as object constants, for example: CSSRule.FONT_FACE_RULE. In 4.2 CSSRule.VARIABLES_RULE was there and now it&#8217;s gone.</p>
<h2>Other changes? Let&#8217;s submit our requests</h2>
<p>I&#8217;ve made a research over the DOM and the CSS variable rule removal is the only visible change between Safari iOS 4.2 and iOS 4.3.The WebKit engine seems to be the same: 533.17.9. So no more big news for now.</p>
<p>At the Mobile World Congress I have met one of the guys behind Safari on iOS, I&#8217;ve talked with him about Safari new features. Of course, he can not talk about future versions. But I would like to highlight one thing: he recommends all the developer community to <strong>fill a <a href="https://bugreport.apple.com/" target="_blank">New Feature Bug Report</a> for new features/abilities that we want to have on the browser.</strong> They really look at them and if many developers want a new feature, they will seriously think about it. (forget about Flash Player for now ;) )</p>
<p><strong>What HTML5/CSS/JS feature do you want to see in next versions?</strong></p>
<p>I want to start my list with:</p>
<ul>
<li>A meta tag to force an orientation mode or at least, to force orientation lock (useful for HTML5 games and DeviceOrientation API apps)</li>
<li>File uploads, at least from the gallery (as the UIImagePickerController available on the native side).</li>
</ul>
<p>What do you think? Leave your comments!</p>
<p>&nbsp;</p>
]]></content:encoded>
			<wfw:commentRss>http://www.mobilexweb.com/blog/safari-ipad-iphone-4-3/feed</wfw:commentRss>
		<slash:comments>17</slash:comments>
		</item>
	</channel>
</rss>

