W3C home > Mailing lists > Public > public-html-diffs@w3.org > December 2008

spec/Overview.html 1.1744 2573 Explain parseInt() usage. (credit: pt) (

From: poot <cvsmail@w3.org>
Date: Wed, 24 Dec 2008 21:23:21 +0900 (JST)
To: public-html-diffs@w3.org
Message-Id: <20081224122321.A61002BC17@toro.w3.mag.keio.ac.jp>

Explain parseInt() usage. (credit: pt) (whatwg r2573)

5.10.1.2 The Storage interface
http://people.w3.org/mike/diffs/html5/spec/Overview.1.1744.html#the-storage-interface

http://people.w3.org/mike/diffs/html5/spec/Overview.diff.html
http://dev.w3.org/cvsweb/html5/spec/Overview.html?r1=1.1743&r2=1.1744&f=h
http://html5.org/tools/web-apps-tracker?from=2572&to=2573

===================================================================
RCS file: /sources/public/html5/spec/Overview.html,v
retrieving revision 1.1743
retrieving revision 1.1744
diff -u -d -r1.1743 -r1.1744
--- Overview.html	24 Dec 2008 12:17:55 -0000	1.1743
+++ Overview.html	24 Dec 2008 12:20:12 -0000	1.1744
@@ -31366,6 +31366,10 @@
   document.getElementById('count').textContent = localStorage.pageLoadCount;
 &lt;/script&gt;</pre>
 
+   <p>The use of <code title="">parseInt()</code> is needed when
+   dealing with numbers (integers in this case) because the storage
+   APIs are all string-based.</p>
+
   </div><p>Each site has its own separate storage area.<p>Storage areas (both session storage and local storage) store
   strings. To store structured data in a storage area, you must first
   convert it to a string.<h5 id=the-storage-interface><span class=secno>5.10.1.2 </span>The <code><a href=#storage-0>Storage</a></code> interface</h5><!-- XXX shouldn't we define somewhere how null values get handled
Received on Wednesday, 24 December 2008 12:23:56 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Saturday, 18 December 2010 06:13:57 GMT