You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by mw...@apache.org on 2013/07/18 21:28:30 UTC
[06/12] Version 3.0.0rc1
http://git-wip-us.apache.org/repos/asf/cordova-docs/blob/17ffa3e5/docs/en/3.0.0rc1/cordova/media/media.pause.md
----------------------------------------------------------------------
diff --git a/docs/en/3.0.0rc1/cordova/media/media.pause.md b/docs/en/3.0.0rc1/cordova/media/media.pause.md
new file mode 100644
index 0000000..0c3712a
--- /dev/null
+++ b/docs/en/3.0.0rc1/cordova/media/media.pause.md
@@ -0,0 +1,167 @@
+---
+license: Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+---
+
+media.pause
+===========
+
+Pauses playing an audio file.
+
+ media.pause();
+
+Description
+-----------
+
+The `media.pause` method executes synchronously, and pauses playing an audio file.
+
+Supported Platforms
+-------------------
+
+- Android
+- BlackBerry WebWorks (OS 5.0 and higher)
+- iOS
+- Windows Phone 7 and 8
+- Tizen
+- Windows 8
+
+Quick Example
+-------------
+
+ // Play audio
+ //
+ function playAudio(url) {
+ // Play the audio file at url
+ var my_media = new Media(url,
+ // success callback
+ function () { console.log("playAudio():Audio Success"); },
+ // error callback
+ function (err) { console.log("playAudio():Audio Error: " + err); }
+ );
+
+ // Play audio
+ my_media.play();
+
+ // Pause after 10 seconds
+ setTimeout(function () {
+ media.pause();
+ }, 10000);
+ }
+
+Full Example
+------------
+
+ <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
+ "http://www.w3.org/TR/html4/strict.dtd">
+ <html>
+ <head>
+ <title>Media Example</title>
+
+ <script type="text/javascript" charset="utf-8" src="cordova-3.0.0.js"></script>
+ <script type="text/javascript" charset="utf-8">
+
+ // Wait for device API libraries to load
+ //
+ document.addEventListener("deviceready", onDeviceReady, false);
+
+ // device APIs are available
+ //
+ function onDeviceReady() {
+ playAudio("http://audio.ibeat.org/content/p1rj1s/p1rj1s_-_rockGuitar.mp3");
+ }
+
+ // Audio player
+ //
+ var my_media = null;
+ var mediaTimer = null;
+
+ // Play audio
+ //
+ function playAudio(src) {
+ // Create Media object from src
+ my_media = new Media(src, onSuccess, onError);
+
+ // Play audio
+ my_media.play();
+
+ // Update my_media position every second
+ if (mediaTimer == null) {
+ mediaTimer = setInterval(function() {
+ // get my_media position
+ my_media.getCurrentPosition(
+ // success callback
+ function(position) {
+ if (position > -1) {
+ setAudioPosition((position) + " sec");
+ }
+ },
+ // error callback
+ function(e) {
+ console.log("Error getting pos=" + e);
+ setAudioPosition("Error: " + e);
+ }
+ );
+ }, 1000);
+ }
+ }
+
+ // Pause audio
+ //
+ function pauseAudio() {
+ if (my_media) {
+ my_media.pause();
+ }
+ }
+
+ // Stop audio
+ //
+ function stopAudio() {
+ if (my_media) {
+ my_media.stop();
+ }
+ clearInterval(mediaTimer);
+ mediaTimer = null;
+ }
+
+ // onSuccess Callback
+ //
+ function onSuccess() {
+ console.log("playAudio():Audio Success");
+ }
+
+ // onError Callback
+ //
+ function onError(error) {
+ alert('code: ' + error.code + '\n' +
+ 'message: ' + error.message + '\n');
+ }
+
+ // Set audio position
+ //
+ function setAudioPosition(position) {
+ document.getElementById('audio_position').innerHTML = position;
+ }
+
+ </script>
+ </head>
+ <body>
+ <a href="#" class="btn large" onclick="playAudio('http://audio.ibeat.org/content/p1rj1s/p1rj1s_-_rockGuitar.mp3');">Play Audio</a>
+ <a href="#" class="btn large" onclick="pauseAudio();">Pause Playing Audio</a>
+ <a href="#" class="btn large" onclick="stopAudio();">Stop Playing Audio</a>
+ <p id="audio_position"></p>
+ </body>
+ </html>
http://git-wip-us.apache.org/repos/asf/cordova-docs/blob/17ffa3e5/docs/en/3.0.0rc1/cordova/media/media.play.md
----------------------------------------------------------------------
diff --git a/docs/en/3.0.0rc1/cordova/media/media.play.md b/docs/en/3.0.0rc1/cordova/media/media.play.md
new file mode 100644
index 0000000..4ddc625
--- /dev/null
+++ b/docs/en/3.0.0rc1/cordova/media/media.play.md
@@ -0,0 +1,200 @@
+---
+license: Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+---
+
+media.play
+==========
+
+Starts or resumes playing an audio file.
+
+ media.play();
+
+Description
+-----------
+
+The `media.play` method executes synchronously, and starts or resumes
+playing an audio file.
+
+Supported Platforms
+-------------------
+
+- Android
+- BlackBerry WebWorks (OS 5.0 and higher)
+- iOS
+- Windows Phone 7 and 8
+- Tizen
+- Windows 8
+
+Quick Example
+-------------
+
+ // Play audio
+ //
+ function playAudio(url) {
+ // Play the audio file at url
+ var my_media = new Media(url,
+ // success callback
+ function () {
+ console.log("playAudio():Audio Success");
+ },
+ // error callback
+ function (err) {
+ console.log("playAudio():Audio Error: " + err);
+ }
+ );
+ // Play audio
+ my_media.play();
+ }
+
+Full Example
+------------
+
+ <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
+ "http://www.w3.org/TR/html4/strict.dtd">
+ <html>
+ <head>
+ <title>Media Example</title>
+
+ <script type="text/javascript" charset="utf-8" src="cordova-3.0.0.js"></script>
+ <script type="text/javascript" charset="utf-8">
+
+ // Wait for device API libraries to load
+ //
+ document.addEventListener("deviceready", onDeviceReady, false);
+
+ // device APIs are available
+ //
+ function onDeviceReady() {
+ playAudio("http://audio.ibeat.org/content/p1rj1s/p1rj1s_-_rockGuitar.mp3");
+ }
+
+ // Audio player
+ //
+ var my_media = null;
+ var mediaTimer = null;
+
+ // Play audio
+ //
+ function playAudio(src) {
+ if (my_media == null) {
+ // Create Media object from src
+ my_media = new Media(src, onSuccess, onError);
+ } // else play current audio
+ // Play audio
+ my_media.play();
+
+ // Update my_media position every second
+ if (mediaTimer == null) {
+ mediaTimer = setInterval(function() {
+ // get my_media position
+ my_media.getCurrentPosition(
+ // success callback
+ function(position) {
+ if (position > -1) {
+ setAudioPosition((position) + " sec");
+ }
+ },
+ // error callback
+ function(e) {
+ console.log("Error getting pos=" + e);
+ setAudioPosition("Error: " + e);
+ }
+ );
+ }, 1000);
+ }
+ }
+
+ // Pause audio
+ //
+ function pauseAudio() {
+ if (my_media) {
+ my_media.pause();
+ }
+ }
+
+ // Stop audio
+ //
+ function stopAudio() {
+ if (my_media) {
+ my_media.stop();
+ }
+ clearInterval(mediaTimer);
+ mediaTimer = null;
+ }
+
+ // onSuccess Callback
+ //
+ function onSuccess() {
+ console.log("playAudio():Audio Success");
+ }
+
+ // onError Callback
+ //
+ function onError(error) {
+ alert('code: ' + error.code + '\n' +
+ 'message: ' + error.message + '\n');
+ }
+
+ // Set audio position
+ //
+ function setAudioPosition(position) {
+ document.getElementById('audio_position').innerHTML = position;
+ }
+
+ </script>
+ </head>
+ <body>
+ <a href="#" class="btn large" onclick="playAudio('http://audio.ibeat.org/content/p1rj1s/p1rj1s_-_rockGuitar.mp3');">Play Audio</a>
+ <a href="#" class="btn large" onclick="pauseAudio();">Pause Playing Audio</a>
+ <a href="#" class="btn large" onclick="stopAudio();">Stop Playing Audio</a>
+ <p id="audio_position"></p>
+ </body>
+ </html>
+
+BlackBerry WebWorks Quirks
+----------
+
+- BlackBerry devices support a limited number of simultaneous audio
+ channels. CDMA devices only support a single audio channel. Other
+ devices support up to two simultaneous channels. An attempt to play
+ more audio files than the supported amount results in previous
+ playback being stopped.
+
+iOS Quirks
+----------
+
+- __numberOfLoops__: Pass this option to the `play` method to specify
+ the number of times you want the media file to play, e.g.:
+
+ var myMedia = new Media("http://audio.ibeat.org/content/p1rj1s/p1rj1s_-_rockGuitar.mp3")
+ myMedia.play({ numberOfLoops: 2 })
+
+- __playAudioWhenScreenIsLocked__: Pass in this option to the `play`
+ method to specify whether you want to allow playback when the screen
+ is locked. If set to `true` (the default value), the state of the
+ hardware mute button is ignored, e.g.:
+
+ var myMedia = new Media("http://audio.ibeat.org/content/p1rj1s/p1rj1s_-_rockGuitar.mp3")
+ myMedia.play({ playAudioWhenScreenIsLocked : false })
+
+- __order of file search__: When only a file name or simple path is
+ provided, iOS searches in the `www` directory for the file, then in
+ the application's `documents/tmp` directory:
+
+ var myMedia = new Media("audio/beer.mp3")
+ myMedia.play() // first looks for file in www/audio/beer.mp3 then in <application>/documents/tmp/audio/beer.mp3
http://git-wip-us.apache.org/repos/asf/cordova-docs/blob/17ffa3e5/docs/en/3.0.0rc1/cordova/media/media.release.md
----------------------------------------------------------------------
diff --git a/docs/en/3.0.0rc1/cordova/media/media.release.md b/docs/en/3.0.0rc1/cordova/media/media.release.md
new file mode 100644
index 0000000..ec6e5b0
--- /dev/null
+++ b/docs/en/3.0.0rc1/cordova/media/media.release.md
@@ -0,0 +1,159 @@
+---
+license: Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+---
+
+media.release
+=================
+
+Releases the underlying operating system's audio resources.
+
+ media.release();
+
+Description
+-----------
+
+The `media.release` method executes synchronously, releasing the
+underlying operating system's audio resources. This is particularly
+important for Android, since there are a finite amount of OpenCore
+instances for media playback. Applications should call the `release`
+function for any `Media` resource that is no longer needed.
+
+Supported Platforms
+-------------------
+
+- Android
+- BlackBerry WebWorks (OS 5.0 and higher)
+- iOS
+- Windows Phone 7 and 8
+- Tizen
+- Windows 8
+
+Quick Example
+-------------
+
+ // Audio player
+ //
+ var my_media = new Media(src, onSuccess, onError);
+
+ my_media.play();
+ my_media.stop();
+ my_media.release();
+
+Full Example
+------------
+
+ <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
+ "http://www.w3.org/TR/html4/strict.dtd">
+ <html>
+ <head>
+ <title>Media Example</title>
+
+ <script type="text/javascript" charset="utf-8" src="cordova-3.0.0.js"></script>
+ <script type="text/javascript" charset="utf-8">
+
+ // Wait for device API libraries to load
+ //
+ document.addEventListener("deviceready", onDeviceReady, false);
+
+ // device APIs are available
+ //
+ function onDeviceReady() {
+ playAudio("http://audio.ibeat.org/content/p1rj1s/p1rj1s_-_rockGuitar.mp3");
+ }
+
+ // Audio player
+ //
+ var my_media = null;
+ var mediaTimer = null;
+
+ // Play audio
+ //
+ function playAudio(src) {
+ // Create Media object from src
+ my_media = new Media(src, onSuccess, onError);
+
+ // Play audio
+ my_media.play();
+
+ // Update my_media position every second
+ if (mediaTimer == null) {
+ mediaTimer = setInterval(function() {
+ // get my_media position
+ my_media.getCurrentPosition(
+ // success callback
+ function(position) {
+ if (position > -1) {
+ setAudioPosition((position) + " sec");
+ }
+ },
+ // error callback
+ function(e) {
+ console.log("Error getting pos=" + e);
+ setAudioPosition("Error: " + e);
+ }
+ );
+ }, 1000);
+ }
+ }
+
+ // Pause audio
+ //
+ function pauseAudio() {
+ if (my_media) {
+ my_media.pause();
+ }
+ }
+
+ // Stop audio
+ //
+ function stopAudio() {
+ if (my_media) {
+ my_media.stop();
+ }
+ clearInterval(mediaTimer);
+ mediaTimer = null;
+ }
+
+ // onSuccess Callback
+ //
+ function onSuccess() {
+ console.log("playAudio():Audio Success");
+ }
+
+ // onError Callback
+ //
+ function onError(error) {
+ alert('code: ' + error.code + '\n' +
+ 'message: ' + error.message + '\n');
+ }
+
+ // Set audio position
+ //
+ function setAudioPosition(position) {
+ document.getElementById('audio_position').innerHTML = position;
+ }
+
+ </script>
+ </head>
+ <body>
+ <a href="#" class="btn large" onclick="playAudio('http://audio.ibeat.org/content/p1rj1s/p1rj1s_-_rockGuitar.mp3');">Play Audio</a>
+ <a href="#" class="btn large" onclick="pauseAudio();">Pause Playing Audio</a>
+ <a href="#" class="btn large" onclick="stopAudio();">Stop Playing Audio</a>
+ <p id="audio_position"></p>
+ </body>
+ </html>
http://git-wip-us.apache.org/repos/asf/cordova-docs/blob/17ffa3e5/docs/en/3.0.0rc1/cordova/media/media.seekTo.md
----------------------------------------------------------------------
diff --git a/docs/en/3.0.0rc1/cordova/media/media.seekTo.md b/docs/en/3.0.0rc1/cordova/media/media.seekTo.md
new file mode 100644
index 0000000..20e5c73
--- /dev/null
+++ b/docs/en/3.0.0rc1/cordova/media/media.seekTo.md
@@ -0,0 +1,161 @@
+---
+license: Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+---
+
+media.seekTo
+========================
+
+Sets the current position within an audio file.
+
+ media.seekTo(milliseconds);
+
+Parameters
+----------
+
+- __milliseconds__: The position to set the playback position within the audio, in milliseconds.
+
+Description
+-----------
+
+The `media.seekTo` executes asynchronously, updating the current
+playback position within an audio file referenced by a `Media`
+object. Also updates the `Media` object's `position` parameter.
+
+Supported Platforms
+-------------------
+
+- Android
+- BlackBerry WebWorks (OS 6.0 and higher)
+- iOS
+- Windows Phone 7 and 8
+- Tizen
+- Windows 8
+
+Quick Example
+-------------
+
+ // Audio player
+ //
+ var my_media = new Media(src, onSuccess, onError);
+ my_media.play();
+ // SeekTo to 10 seconds after 5 seconds
+ setTimeout(function() {
+ my_media.seekTo(10000);
+ }, 5000);
+
+Full Example
+------------
+
+ <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
+ "http://www.w3.org/TR/html4/strict.dtd">
+ <html>
+ <head>
+ <title>Media Example</title>
+
+ <script type="text/javascript" charset="utf-8" src="cordova-3.0.0.js"></script>
+ <script type="text/javascript" charset="utf-8">
+
+ // Wait for device API libraries to load
+ //
+ document.addEventListener("deviceready", onDeviceReady, false);
+
+ // device APIs are available
+ //
+ function onDeviceReady() {
+ playAudio("http://audio.ibeat.org/content/p1rj1s/p1rj1s_-_rockGuitar.mp3");
+ }
+
+ // Audio player
+ //
+ var my_media = null;
+ var mediaTimer = null;
+
+ // Play audio
+ //
+ function playAudio(src) {
+ // Create Media object from src
+ my_media = new Media(src, onSuccess, onError);
+
+ // Play audio
+ my_media.play();
+
+ // Update media position every second
+ mediaTimer = setInterval(function() {
+ // get media position
+ my_media.getCurrentPosition(
+ // success callback
+ function(position) {
+ if (position > -1) {
+ setAudioPosition(position + " sec");
+ }
+ },
+ // error callback
+ function(e) {
+ console.log("Error getting pos=" + e);
+ }
+ );
+ }, 1000);
+
+ // SeekTo to 10 seconds after 5 seconds
+ setTimeout(function() {
+ my_media.seekTo(10000);
+ }, 5000);
+ }
+
+ // Stop audio
+ //
+ function stopAudio() {
+ if (my_media) {
+ my_media.stop();
+ }
+ clearInterval(mediaTimer);
+ mediaTimer = null;
+ }
+
+ // onSuccess Callback
+ //
+ function onSuccess() {
+ console.log("playAudio():Audio Success");
+ }
+
+ // onError Callback
+ //
+ function onError(error) {
+ alert('code: ' + error.code + '\n' +
+ 'message: ' + error.message + '\n');
+ }
+
+ // Set audio position
+ //
+ function setAudioPosition(position) {
+ document.getElementById('audio_position').innerHTML = position;
+ }
+
+ </script>
+ </head>
+ <body>
+ <a href="#" class="btn large" onclick="playAudio('http://audio.ibeat.org/content/p1rj1s/p1rj1s_-_rockGuitar.mp3');">Play Audio</a>
+ <a href="#" class="btn large" onclick="stopAudio();">Stop Playing Audio</a>
+ <p id="audio_position"></p>
+ </body>
+ </html>
+
+BlackBerry WebWorks Quirks
+----------
+
+- Not supported on BlackBerry OS 5 devices.
http://git-wip-us.apache.org/repos/asf/cordova-docs/blob/17ffa3e5/docs/en/3.0.0rc1/cordova/media/media.setVolume.md
----------------------------------------------------------------------
diff --git a/docs/en/3.0.0rc1/cordova/media/media.setVolume.md b/docs/en/3.0.0rc1/cordova/media/media.setVolume.md
new file mode 100644
index 0000000..b3c4ac6
--- /dev/null
+++ b/docs/en/3.0.0rc1/cordova/media/media.setVolume.md
@@ -0,0 +1,178 @@
+---
+license: Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+---
+
+media.setVolume
+===========
+
+Set the volume for an audio file.
+
+ media.setVolume(volume);
+
+Paramters
+---------
+
+- __volume__: The volume to set for playback. The value must be within the range of 0.0 to 1.0.
+
+Description
+-----------
+
+Function `media.setVolume` is an asynchronous function that sets the volume during audio playback.
+
+Supported Platforms
+-------------------
+
+- Android
+- iOS
+
+Quick Example
+-------------
+
+ // Play audio
+ //
+ function playAudio(url) {
+ // Play the audio file at url
+ var my_media = new Media(url,
+ // success callback
+ function() {
+ console.log("playAudio():Audio Success");
+ },
+ // error callback
+ function(err) {
+ console.log("playAudio():Audio Error: "+err);
+ });
+
+ // Play audio
+ my_media.play();
+
+ // Mute volume after 2 seconds
+ setTimeout(function() {
+ my_media.setVolume('0.0');
+ }, 2000);
+
+ // Set volume to 1.0 after 5 seconds
+ setTimeout(function() {
+ my_media.setVolume('1.0');
+ }, 5000);
+ }
+
+
+Full Example
+------------
+
+ <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
+ "http://www.w3.org/TR/html4/strict.dtd">
+ <html>
+ <head>
+ <title>Media Example</title>
+
+ <script type="text/javascript" charset="utf-8" src="cordova-3.0.0.js"></script>
+ <script type="text/javascript" charset="utf-8">
+
+ // Wait for Cordova to load
+ //
+ document.addEventListener("deviceready", onDeviceReady, false);
+
+ // Cordova is ready
+ //
+ function onDeviceReady() {
+ playAudio("http://audio.ibeat.org/content/p1rj1s/p1rj1s_-_rockGuitar.mp3");
+ }
+
+ // Audio player
+ //
+ var my_media = null;
+ var mediaTimer = null;
+
+ // Play audio
+ //
+ function playAudio(src) {
+ // Create Media object from src
+ my_media = new Media(src, onSuccess, onError);
+
+ // Play audio
+ my_media.play();
+
+ // Update my_media position every second
+ if (mediaTimer == null) {
+ mediaTimer = setInterval(function() {
+ // get my_media position
+ my_media.getCurrentPosition(
+ // success callback
+ function(position) {
+ if (position > -1) {
+ setAudioPosition((position) + " sec");
+ }
+ },
+ // error callback
+ function(e) {
+ console.log("Error getting pos=" + e);
+ setAudioPosition("Error: " + e);
+ }
+ );
+ }, 1000);
+ }
+ }
+
+ // Set audio volume
+ //
+ function setVolume(volume) {
+ if (my_media) {
+ my_media.setVolume(volume);
+ }
+ }
+
+ // Stop audio
+ //
+ function stopAudio() {
+ if (my_media) {
+ my_media.stop();
+ }
+ clearInterval(mediaTimer);
+ mediaTimer = null;
+ }
+
+ // onSuccess Callback
+ //
+ function onSuccess() {
+ console.log("playAudio():Audio Success");
+ }
+
+ // onError Callback
+ //
+ function onError(error) {
+ alert('code: ' + error.code + '\n' +
+ 'message: ' + error.message + '\n');
+ }
+
+ // Set audio position
+ //
+ function setAudioPosition(position) {
+ document.getElementById('audio_position').innerHTML = position;
+ }
+
+ </script>
+ </head>
+ <body>
+ <a href="#" class="btn large" onclick="playAudio('http://audio.ibeat.org/content/p1rj1s/p1rj1s_-_rockGuitar.mp3');">Play Audio</a>
+ <a href="#" class="btn large" onclick="setVolume('0.0');">Mute Audio</a>
+ <a href="#" class="btn large" onclick="setVolume('1.0');">Unmute Audio</a>
+ <a href="#" class="btn large" onclick="stopAudio();">Stop Playing Audio</a>
+ <p id="audio_position"></p>
+ </body>
+ </html>
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/cordova-docs/blob/17ffa3e5/docs/en/3.0.0rc1/cordova/media/media.startRecord.md
----------------------------------------------------------------------
diff --git a/docs/en/3.0.0rc1/cordova/media/media.startRecord.md b/docs/en/3.0.0rc1/cordova/media/media.startRecord.md
new file mode 100644
index 0000000..76eff26
--- /dev/null
+++ b/docs/en/3.0.0rc1/cordova/media/media.startRecord.md
@@ -0,0 +1,155 @@
+---
+license: Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+---
+
+media.startRecord
+=================
+
+Starts recording an audio file.
+
+ media.startRecord();
+
+Description
+-----------
+
+The `media.startRecord` method executes synchronously, starts a
+recording for an audio file.
+
+Supported Platforms
+-------------------
+
+- Android
+- BlackBerry WebWorks (OS 5.0 and higher)
+- iOS
+- Windows Phone 7 and 8
+- Windows 8
+
+Quick Example
+-------------
+
+ // Record audio
+ //
+ function recordAudio() {
+ var src = "myrecording.mp3";
+ var mediaRec = new Media(src,
+ // success callback
+ function() {
+ console.log("recordAudio():Audio Success");
+ },
+
+ // error callback
+ function(err) {
+ console.log("recordAudio():Audio Error: "+ err.code);
+ });
+
+ // Record audio
+ mediaRec.startRecord();
+ }
+
+Full Example
+------------
+
+ <!DOCTYPE html>
+ <html>
+ <head>
+ <title>Device Properties Example</title>
+
+ <script type="text/javascript" charset="utf-8" src="cordova-3.0.0.js"></script>
+ <script type="text/javascript" charset="utf-8">
+
+ // Wait for device API libraries to load
+ //
+ document.addEventListener("deviceready", onDeviceReady, false);
+
+ // Record audio
+ //
+ function recordAudio() {
+ var src = "myrecording.amr";
+ var mediaRec = new Media(src, onSuccess, onError);
+
+ // Record audio
+ mediaRec.startRecord();
+
+ // Stop recording after 10 sec
+ var recTime = 0;
+ var recInterval = setInterval(function() {
+ recTime = recTime + 1;
+ setAudioPosition(recTime + " sec");
+ if (recTime >= 10) {
+ clearInterval(recInterval);
+ mediaRec.stopRecord();
+ }
+ }, 1000);
+ }
+
+ // device APIs are available
+ //
+ function onDeviceReady() {
+ recordAudio();
+ }
+
+ // onSuccess Callback
+ //
+ function onSuccess() {
+ console.log("recordAudio():Audio Success");
+ }
+
+ // onError Callback
+ //
+ function onError(error) {
+ alert('code: ' + error.code + '\n' +
+ 'message: ' + error.message + '\n');
+ }
+
+ // Set audio position
+ //
+ function setAudioPosition(position) {
+ document.getElementById('audio_position').innerHTML = position;
+ }
+
+ </script>
+ </head>
+ <body>
+ <p id="media">Recording audio...</p>
+ <p id="audio_position"></p>
+ </body>
+ </html>
+
+Android Quirks
+----------
+
+- Android devices record audio in Adaptive Multi-Rate format. The specified file should end with a _.amr_ extension.
+
+BlackBerry WebWorks Quirks
+----------
+
+- BlackBerry devices record audio in Adaptive Multi-Rate format. The specified file must end with a _.amr_ extension.
+
+iOS Quirks
+----------
+
+- iOS only records to files of type _.wav_ and returns an error if the file name extension is not correct.
+- If a full path is not provided, the recording is placed in the application's `documents/tmp` directory. This can be accessed via the `File` API using `LocalFileSystem.TEMPORARY`. Any subdirectory specified at record time must already exist.
+- Files can be recorded and played back using the documents URI:
+
+ var myMedia = new Media("documents://beer.mp3")
+
+Tizen Quirks
+----------
+
+- Not supported on Tizen devices.
http://git-wip-us.apache.org/repos/asf/cordova-docs/blob/17ffa3e5/docs/en/3.0.0rc1/cordova/media/media.stop.md
----------------------------------------------------------------------
diff --git a/docs/en/3.0.0rc1/cordova/media/media.stop.md b/docs/en/3.0.0rc1/cordova/media/media.stop.md
new file mode 100644
index 0000000..ec53ea9
--- /dev/null
+++ b/docs/en/3.0.0rc1/cordova/media/media.stop.md
@@ -0,0 +1,172 @@
+---
+license: Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+---
+
+media.stop
+==========
+
+Stops playing an audio file.
+
+ media.stop();
+
+Description
+-----------
+
+The `media.stop` method executes synchronously to stop playing an
+audio file.
+
+Supported Platforms
+-------------------
+
+- Android
+- BlackBerry WebWorks (OS 5.0 and higher)
+- iOS
+- Windows Phone 7 and 8
+- Tizen
+- Windows 8
+
+Quick Example
+-------------
+
+ // Play audio
+ //
+ function playAudio(url) {
+ // Play the audio file at url
+ var my_media = new Media(url,
+ // success callback
+ function() {
+ console.log("playAudio():Audio Success");
+ },
+ // error callback
+ function(err) {
+ console.log("playAudio():Audio Error: "+err);
+ }
+ );
+
+ // Play audio
+ my_media.play();
+
+ // Pause after 10 seconds
+ setTimeout(function() {
+ my_media.stop();
+ }, 10000);
+ }
+
+Full Example
+------------
+
+ <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
+ "http://www.w3.org/TR/html4/strict.dtd">
+ <html>
+ <head>
+ <title>Media Example</title>
+
+ <script type="text/javascript" charset="utf-8" src="cordova-3.0.0.js"></script>
+ <script type="text/javascript" charset="utf-8">
+
+ // Wait for device API libraries to load
+ //
+ document.addEventListener("deviceready", onDeviceReady, false);
+
+ // device APIs are available
+ //
+ function onDeviceReady() {
+ playAudio("http://audio.ibeat.org/content/p1rj1s/p1rj1s_-_rockGuitar.mp3");
+ }
+
+ // Audio player
+ //
+ var my_media = null;
+ var mediaTimer = null;
+
+ // Play audio
+ //
+ function playAudio(src) {
+ // Create Media object from src
+ my_media = new Media(src, onSuccess, onError);
+
+ // Play audio
+ my_media.play();
+
+ // Update my_media position every second
+ if (mediaTimer == null) {
+ mediaTimer = setInterval(function() {
+ // get my_media position
+ my_media.getCurrentPosition(
+ // success callback
+ function(position) {
+ if (position > -1) {
+ setAudioPosition((position) + " sec");
+ }
+ },
+ // error callback
+ function(e) {
+ console.log("Error getting pos=" + e);
+ setAudioPosition("Error: " + e);
+ }
+ );
+ }, 1000);
+ }
+ }
+
+ // Pause audio
+ //
+ function pauseAudio() {
+ if (my_media) {
+ my_media.pause();
+ }
+ }
+
+ // Stop audio
+ //
+ function stopAudio() {
+ if (my_media) {
+ my_media.stop();
+ }
+ clearInterval(mediaTimer);
+ mediaTimer = null;
+ }
+
+ // onSuccess Callback
+ //
+ function onSuccess() {
+ console.log("playAudio():Audio Success");
+ }
+
+ // onError Callback
+ //
+ function onError(error) {
+ alert('code: ' + error.code + '\n' +
+ 'message: ' + error.message + '\n');
+ }
+
+ // Set audio position
+ //
+ function setAudioPosition(position) {
+ document.getElementById('audio_position').innerHTML = position;
+ }
+
+ </script>
+ </head>
+ <body>
+ <a href="#" class="btn large" onclick="playAudio('http://audio.ibeat.org/content/p1rj1s/p1rj1s_-_rockGuitar.mp3');">Play Audio</a>
+ <a href="#" class="btn large" onclick="pauseAudio();">Pause Playing Audio</a>
+ <a href="#" class="btn large" onclick="stopAudio();">Stop Playing Audio</a>
+ <p id="audio_position"></p>
+ </body>
+ </html>
http://git-wip-us.apache.org/repos/asf/cordova-docs/blob/17ffa3e5/docs/en/3.0.0rc1/cordova/media/media.stopRecord.md
----------------------------------------------------------------------
diff --git a/docs/en/3.0.0rc1/cordova/media/media.stopRecord.md b/docs/en/3.0.0rc1/cordova/media/media.stopRecord.md
new file mode 100644
index 0000000..f71324e
--- /dev/null
+++ b/docs/en/3.0.0rc1/cordova/media/media.stopRecord.md
@@ -0,0 +1,142 @@
+---
+license: Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+---
+
+media.stopRecord
+================
+
+Stops recording an audio file.
+
+ media.stopRecord();
+
+Description
+-----------
+
+The `media.stopRecord` method executes synchronously, stopping the
+recording of an audio file.
+
+Supported Platforms
+-------------------
+
+- Android
+- BlackBerry WebWorks (OS 5.0 and higher)
+- iOS
+- Windows Phone 7 and 8
+- Windows 8
+
+Quick Example
+-------------
+
+ // Record audio
+ //
+ function recordAudio() {
+ var src = "myrecording.mp3";
+ var mediaRec = new Media(src,
+ // success callback
+ function() {
+ console.log("recordAudio():Audio Success");
+ },
+
+ // error callback
+ function(err) {
+ console.log("recordAudio():Audio Error: "+ err.code);
+ }
+ );
+
+ // Record audio
+ mediaRec.startRecord();
+
+ // Stop recording after 10 seconds
+ setTimeout(function() {
+ mediaRec.stopRecord();
+ }, 10000);
+ }
+
+Full Example
+------------
+
+ <!DOCTYPE html>
+ <html>
+ <head>
+ <title>Device Properties Example</title>
+
+ <script type="text/javascript" charset="utf-8" src="cordova-3.0.0.js"></script>
+ <script type="text/javascript" charset="utf-8">
+
+ // Wait for device API libraries to load
+ //
+ document.addEventListener("deviceready", onDeviceReady, false);
+
+ // Record audio
+ //
+ function recordAudio() {
+ var src = "myrecording.mp3";
+ var mediaRec = new Media(src, onSuccess, onError);
+
+ // Record audio
+ mediaRec.startRecord();
+
+ // Stop recording after 10 sec
+ var recTime = 0;
+ var recInterval = setInterval(function() {
+ recTime = recTime + 1;
+ setAudioPosition(recTime + " sec");
+ if (recTime >= 10) {
+ clearInterval(recInterval);
+ mediaRec.stopRecord();
+ }
+ }, 1000);
+ }
+
+ // device APIs are available
+ //
+ function onDeviceReady() {
+ recordAudio();
+ }
+
+ // onSuccess Callback
+ //
+ function onSuccess() {
+ console.log("recordAudio():Audio Success");
+ }
+
+ // onError Callback
+ //
+ function onError(error) {
+ alert('code: ' + error.code + '\n' +
+ 'message: ' + error.message + '\n');
+ }
+
+ // Set audio position
+ //
+ function setAudioPosition(position) {
+ document.getElementById('audio_position').innerHTML = position;
+ }
+
+ </script>
+ </head>
+ <body>
+ <p id="media">Recording audio...</p>
+ <p id="audio_position"></p>
+ </body>
+ </html>
+
+Tizen Quirks
+----------
+
+- Not supported on Tizen devices.
http://git-wip-us.apache.org/repos/asf/cordova-docs/blob/17ffa3e5/docs/en/3.0.0rc1/cordova/notification/notification.alert.md
----------------------------------------------------------------------
diff --git a/docs/en/3.0.0rc1/cordova/notification/notification.alert.md b/docs/en/3.0.0rc1/cordova/notification/notification.alert.md
new file mode 100644
index 0000000..8935b22
--- /dev/null
+++ b/docs/en/3.0.0rc1/cordova/notification/notification.alert.md
@@ -0,0 +1,117 @@
+---
+license: Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+---
+
+notification.alert
+==================
+
+Shows a custom alert or dialog box.
+
+ navigator.notification.alert(message, alertCallback, [title], [buttonName])
+
+- __message__: Dialog message. _(String)_
+- __alertCallback__: Callback to invoke when alert dialog is dismissed. _(Function)_
+- __title__: Dialog title. _(String)_ (Optional, defaults to `Alert`)
+- __buttonName__: Button name. _(String)_ (Optional, defaults to `OK`)
+
+Description
+-----------
+
+Most Cordova implementations use a native dialog box for this feature,
+but some platforms use the browser's `alert` function, which is
+typically less customizable.
+
+Supported Platforms
+-------------------
+
+- Android
+- BlackBerry WebWorks (OS 5.0 and higher)
+- iOS
+- Tizen
+- Windows Phone 7 and 8
+- Windows 8
+
+Quick Example
+-------------
+
+ // Android / BlackBerry WebWorks (OS 5.0 and higher) / iOS / Tizen
+ //
+ function alertDismissed() {
+ // do something
+ }
+
+ navigator.notification.alert(
+ 'You are the winner!', // message
+ alertDismissed, // callback
+ 'Game Over', // title
+ 'Done' // buttonName
+ );
+
+Full Example
+------------
+
+ <!DOCTYPE html>
+ <html>
+ <head>
+ <title>Notification Example</title>
+
+ <script type="text/javascript" charset="utf-8" src="cordova-3.0.0.js"></script>
+ <script type="text/javascript" charset="utf-8">
+
+ // Wait for device API libraries to load
+ //
+ document.addEventListener("deviceready", onDeviceReady, false);
+
+ // device APIs are available
+ //
+ function onDeviceReady() {
+ // Empty
+ }
+
+ // alert dialog dismissed
+ function alertDismissed() {
+ // do something
+ }
+
+ // Show a custom alertDismissed
+ //
+ function showAlert() {
+ navigator.notification.alert(
+ 'You are the winner!', // message
+ alertDismissed, // callback
+ 'Game Over', // title
+ 'Done' // buttonName
+ );
+ }
+
+ </script>
+ </head>
+ <body>
+ <p><a href="#" onclick="showAlert(); return false;">Show Alert</a></p>
+ </body>
+ </html>
+
+Windows Phone 7 and 8 Quirks
+-------------
+
+- There is no built-in browser alert, but you can bind one as follows to call `alert()` in the global scope:
+
+ window.alert = navigator.notification.alert;
+
+- Both `alert` and `confirm` are non-blocking calls, results of which are only available asynchronously.
+
http://git-wip-us.apache.org/repos/asf/cordova-docs/blob/17ffa3e5/docs/en/3.0.0rc1/cordova/notification/notification.beep.md
----------------------------------------------------------------------
diff --git a/docs/en/3.0.0rc1/cordova/notification/notification.beep.md b/docs/en/3.0.0rc1/cordova/notification/notification.beep.md
new file mode 100644
index 0000000..bcddc07
--- /dev/null
+++ b/docs/en/3.0.0rc1/cordova/notification/notification.beep.md
@@ -0,0 +1,111 @@
+---
+license: Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+---
+
+notification.beep
+=================
+
+The device plays a beep sound.
+
+ navigator.notification.beep(times);
+
+- __times__: The number of times to repeat the beep. _(Number)_
+
+Supported Platforms
+-------------------
+
+- Android
+- BlackBerry WebWorks (OS 5.0 and higher)
+- iOS
+- Tizen
+- Windows Phone 7 and 8
+
+Quick Example
+-------------
+
+ // Beep twice!
+ navigator.notification.beep(2);
+
+Full Example
+------------
+
+ <!DOCTYPE html>
+ <html>
+ <head>
+ <title>Notification Example</title>
+
+ <script type="text/javascript" charset="utf-8" src="cordova-3.0.0.js"></script>
+ <script type="text/javascript" charset="utf-8">
+
+ // Wait for device API libraries to load
+ //
+ document.addEventListener("deviceready", onDeviceReady, false);
+
+ // device APIs are available
+ //
+ function onDeviceReady() {
+ // Empty
+ }
+
+ // Show a custom alert
+ //
+ function showAlert() {
+ navigator.notification.alert(
+ 'You are the winner!', // message
+ 'Game Over', // title
+ 'Done' // buttonName
+ );
+ }
+
+ // Beep three times
+ //
+ function playBeep() {
+ navigator.notification.beep(3);
+ }
+
+ // Vibrate for 2 seconds
+ //
+ function vibrate() {
+ navigator.notification.vibrate(2000);
+ }
+
+ </script>
+ </head>
+ <body>
+ <p><a href="#" onclick="showAlert(); return false;">Show Alert</a></p>
+ <p><a href="#" onclick="playBeep(); return false;">Play Beep</a></p>
+ <p><a href="#" onclick="vibrate(); return false;">Vibrate</a></p>
+ </body>
+ </html>
+
+Android Quirks
+--------------
+
+- Android plays the default __Notification ringtone__ specified under the __Settings/Sound & Display__ panel.
+
+Windows Phone 7 and 8 Quirks
+-------------
+
+- Relies on a generic beep file from the Cordova distribution.
+
+Tizen Quirks
+-------------
+
+- Tizen implements beeps by playing an audio file via the media API.
+- The beep file must be short, must be located in a `sounds` sub-directory of the application's root directory, and must be named `beep.wav`.
+
http://git-wip-us.apache.org/repos/asf/cordova-docs/blob/17ffa3e5/docs/en/3.0.0rc1/cordova/notification/notification.confirm.md
----------------------------------------------------------------------
diff --git a/docs/en/3.0.0rc1/cordova/notification/notification.confirm.md b/docs/en/3.0.0rc1/cordova/notification/notification.confirm.md
new file mode 100755
index 0000000..77c581a
--- /dev/null
+++ b/docs/en/3.0.0rc1/cordova/notification/notification.confirm.md
@@ -0,0 +1,129 @@
+---
+license: Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+---
+
+notification.confirm
+====================
+
+Displays a customizable confirmation dialog box.
+
+ navigator.notification.confirm(message, confirmCallback, [title], [buttonLabels])
+
+- __message__: Dialog message. _(String)_
+- __confirmCallback__: Callback to invoke with index of button pressed (1, 2, or 3) or when the dialog is dismissed without a button press (0). _(Function)_
+- __title__: Dialog title. _(String)_ (Optional, defaults to `Confirm`)
+- __buttonLabels__: Comma-separated string specifying button labels. _(String)_ (Optional, defaults to `OK,Cancel`)
+
+Description
+-----------
+
+The `notification.confirm` method displays a native dialog box that is
+more customizable than the browser's `confirm` function.
+
+confirmCallback
+---------------
+
+The `confirmCallback` executes when the user presses one of the
+buttons in the confirmation dialog box.
+
+The callback takes the argument `buttonIndex` _(Number)_, which is the
+index of the pressed button. Note that the index uses one-based
+indexing, so the value is `1`, `2`, `3`, etc.
+
+Supported Platforms
+-------------------
+
+- Android
+- BlackBerry WebWorks (OS 5.0 and higher)
+- iOS
+- Tizen
+- Windows Phone 7 and 8
+- Windows 8
+
+Quick Example
+-------------
+
+ // process the confirmation dialog result
+ function onConfirm(buttonIndex) {
+ alert('You selected button ' + buttonIndex);
+ }
+
+ // Show a custom confirmation dialog
+ //
+ function showConfirm() {
+ navigator.notification.confirm(
+ 'You are the winner!', // message
+ onConfirm, // callback to invoke with index of button pressed
+ 'Game Over', // title
+ 'Restart,Exit' // buttonLabels
+ );
+ }
+
+Full Example
+------------
+
+ <!DOCTYPE html>
+ <html>
+ <head>
+ <title>Notification Example</title>
+
+ <script type="text/javascript" charset="utf-8" src="cordova-3.0.0.js"></script>
+ <script type="text/javascript" charset="utf-8">
+
+ // Wait for device API libraries to load
+ //
+ document.addEventListener("deviceready", onDeviceReady, false);
+
+ // device APIs are available
+ //
+ function onDeviceReady() {
+ // Empty
+ }
+
+ // process the confirmation dialog result
+ function onConfirm(buttonIndex) {
+ alert('You selected button ' + buttonIndex);
+ }
+
+ // Show a custom confirmation dialog
+ //
+ function showConfirm() {
+ navigator.notification.confirm(
+ 'You are the winner!', // message
+ onConfirm, // callback to invoke with index of button pressed
+ 'Game Over', // title
+ 'Restart,Exit' // buttonLabels
+ );
+ }
+
+ </script>
+ </head>
+ <body>
+ <p><a href="#" onclick="showConfirm(); return false;">Show Confirm</a></p>
+ </body>
+ </html>
+
+Windows Phone 7 and 8 Quirks
+----------------------
+
+- There is no built-in browser function for `window.confirm`, but you can bind it by assigning:
+
+ window.confirm = navigator.notification.confirm;
+
+- Calls to `alert` and `confirm` are non-blocking, so the result is only available asynchronously.
+
http://git-wip-us.apache.org/repos/asf/cordova-docs/blob/17ffa3e5/docs/en/3.0.0rc1/cordova/notification/notification.md
----------------------------------------------------------------------
diff --git a/docs/en/3.0.0rc1/cordova/notification/notification.md b/docs/en/3.0.0rc1/cordova/notification/notification.md
new file mode 100644
index 0000000..d72d51b
--- /dev/null
+++ b/docs/en/3.0.0rc1/cordova/notification/notification.md
@@ -0,0 +1,69 @@
+---
+license: Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+---
+
+Notification
+============
+
+> Visual, audible, and tactile device notifications.
+
+Methods
+-------
+
+- `notification.alert`
+- `notification.confirm`
+- `notification.prompt`
+- `notification.beep`
+- `notification.vibrate`
+
+Permissions
+-----------
+
+### Android
+
+#### app/res/xml/config.xml
+
+ <plugin name="Notification" value="org.apache.cordova.Notification"/>
+
+#### app/AndroidManifest.xml
+
+ <uses-permission android:name="android.permission.VIBRATE" />
+
+### BlackBerry WebWorks
+
+#### www/plugins.xml
+
+ <plugin name="Notification" value="org.apache.cordova.notification.Notification" />
+
+#### www/config.xml
+
+ <feature id="blackberry.ui.dialog" />
+
+### iOS
+
+#### config.xml
+
+ <plugin name="Notification" value="CDVNotification" />
+
+### Windows Phone
+
+ No permissions are required.
+
+### Tizen
+
+ No permissions are required.
http://git-wip-us.apache.org/repos/asf/cordova-docs/blob/17ffa3e5/docs/en/3.0.0rc1/cordova/notification/notification.prompt.md
----------------------------------------------------------------------
diff --git a/docs/en/3.0.0rc1/cordova/notification/notification.prompt.md b/docs/en/3.0.0rc1/cordova/notification/notification.prompt.md
new file mode 100644
index 0000000..8b654c7
--- /dev/null
+++ b/docs/en/3.0.0rc1/cordova/notification/notification.prompt.md
@@ -0,0 +1,124 @@
+---
+license: Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+---
+
+notification.prompt
+====================
+
+Shows a customizable prompt dialog box.
+
+ navigator.notification.prompt(message, promptCallback, [title], [buttonLabels], [defaultText])
+
+- __message__: Dialog message. _(String)_
+- __promptCallback__: Callback to invoke when a button is pressed. _(Function)_
+- __title__: Dialog title _(String)_ (Optional, defaults to `Prompt`)
+- __buttonLabels__: Array of strings specifying button labels _(Array)_ (Optional, defaults to `["OK","Cancel"]`)
+- __defaultText__: Default textbox input value (`String`) (Optional, Default: "Default text")
+
+Description
+-----------
+
+The `notification.prompt` method displays a native dialog box that is
+more customizable than the browser's `prompt` function.
+
+promptCallback
+---------------
+
+The `promptCallback` executes when the user presses one of the buttons
+in the prompt dialog box. The `results` object passed to the callback
+contains the following properties:
+
+- __buttonIndex__: The index of the pressed button. _(Number)_ Note that the index uses one-based indexing, so the value is `1`, `2`, `3`, etc.
+- __input1__: The text entered in the prompt dialog box. _(String)_
+
+Supported Platforms
+-------------------
+
+- Android
+- iOS
+
+Quick Example
+-------------
+
+ // process the promp dialog results
+ function onPrompt(results) {
+ alert("You selected button number " + results.buttonIndex + " and entered " + results.input1);
+ }
+
+ // Show a custom prompt dialog
+ //
+ function showPrompt() {
+ navigator.notification.prompt(
+ 'Please enter your name', // message
+ onPrompt, // callback to invoke
+ 'Registration', // title
+ ['Ok','Exit'], // buttonLabels
+ 'Jane Doe' // defaultText
+ );
+ }
+
+Full Example
+------------
+
+ <!DOCTYPE html>
+ <html>
+ <head>
+ <title>Notification Prompt Dialog Example</title>
+
+ <script type="text/javascript" charset="utf-8" src="cordova-3.0.0.js"></script>
+ <script type="text/javascript" charset="utf-8">
+
+ // Wait for device API libraries to load
+ //
+ document.addEventListener("deviceready", onDeviceReady, false);
+
+ // device APIs are available
+ //
+ function onDeviceReady() {
+ // Empty
+ }
+
+ // process the promptation dialog result
+ function onPrompt(results) {
+ alert("You selected button number " + results.buttonIndex + " and entered " + results.input1);
+ }
+
+ // Show a custom prompt dialog
+ //
+ function showPrompt() {
+ navigator.notification.prompt(
+ 'Please enter your name', // message
+ onPrompt, // callback to invoke
+ 'Registration', // title
+ ['Ok','Exit'], // buttonLabels
+ 'Jane Doe' // defaultText
+ );
+ }
+
+ </script>
+ </head>
+ <body>
+ <p><a href="#" onclick="showPrompt(); return false;">Show Prompt</a></p>
+ </body>
+ </html>
+
+Android Quirks
+----------------------
+
+- Android supports a maximum of three buttons, and ignores any more than that.
+- On Android 3.0 and later, buttons are displayed in reverse order for devices that use the Holo theme.
http://git-wip-us.apache.org/repos/asf/cordova-docs/blob/17ffa3e5/docs/en/3.0.0rc1/cordova/notification/notification.vibrate.md
----------------------------------------------------------------------
diff --git a/docs/en/3.0.0rc1/cordova/notification/notification.vibrate.md b/docs/en/3.0.0rc1/cordova/notification/notification.vibrate.md
new file mode 100644
index 0000000..ecf8cdb
--- /dev/null
+++ b/docs/en/3.0.0rc1/cordova/notification/notification.vibrate.md
@@ -0,0 +1,102 @@
+---
+license: Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+---
+
+notification.vibrate
+====================
+
+Vibrates the device for the specified amount of time.
+
+ navigator.notification.vibrate(milliseconds)
+
+- __time__: Milliseconds to vibrate the device, where 1000 milliseconds equals 1 second. _(Number)_
+
+Supported Platforms
+-------------------
+
+- Android
+- BlackBerry WebWorks (OS 5.0 and higher)
+- iOS
+- Windows Phone 7 and 8
+
+Quick Example
+-------------
+
+ // Vibrate for 2.5 seconds
+ //
+ navigator.notification.vibrate(2500);
+
+Full Example
+------------
+
+ <!DOCTYPE html>
+ <html>
+ <head>
+ <title>Notification Example</title>
+
+ <script type="text/javascript" charset="utf-8" src="cordova-3.0.0.js"></script>
+ <script type="text/javascript" charset="utf-8">
+
+ // Wait for device API libraries to load
+ //
+ document.addEventListener("deviceready", onDeviceReady, false);
+
+ // device APIs are available
+ //
+ function onDeviceReady() {
+ // Empty
+ }
+
+ // Show a custom alert
+ //
+ function showAlert() {
+ navigator.notification.alert(
+ 'You are the winner!', // message
+ 'Game Over', // title
+ 'Done' // buttonName
+ );
+ }
+
+ // Beep three times
+ //
+ function playBeep() {
+ navigator.notification.beep(3);
+ }
+
+ // Vibrate for 2 seconds
+ //
+ function vibrate() {
+ navigator.notification.vibrate(2000);
+ }
+
+ </script>
+ </head>
+ <body>
+ <p><a href="#" onclick="showAlert(); return false;">Show Alert</a></p>
+ <p><a href="#" onclick="playBeep(); return false;">Play Beep</a></p>
+ <p><a href="#" onclick="vibrate(); return false;">Vibrate</a></p>
+ </body>
+ </html>
+
+iOS Quirks
+-------------
+
+- __time__: Ignores the specified time and vibrates for a pre-set amount of time.
+
+ navigator.notification.vibrate();
+ navigator.notification.vibrate(2500); // 2500 is ignored
http://git-wip-us.apache.org/repos/asf/cordova-docs/blob/17ffa3e5/docs/en/3.0.0rc1/cordova/splashscreen/splashscreen.hide.md
----------------------------------------------------------------------
diff --git a/docs/en/3.0.0rc1/cordova/splashscreen/splashscreen.hide.md b/docs/en/3.0.0rc1/cordova/splashscreen/splashscreen.hide.md
new file mode 100644
index 0000000..2ef8c77
--- /dev/null
+++ b/docs/en/3.0.0rc1/cordova/splashscreen/splashscreen.hide.md
@@ -0,0 +1,80 @@
+---
+license: Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+---
+
+splashscreen.hide
+===============
+
+Dismiss the splash screen.
+
+ navigator.splashscreen.hide();
+
+Description
+-----------
+
+This method dismisses the application's splash screen.
+
+Supported Platforms
+-------------------
+
+- Android
+- iOS
+
+Quick Example
+-------------
+
+ navigator.splashscreen.hide();
+
+Full Example
+------------
+
+ <!DOCTYPE html>
+ <html>
+ <head>
+ <title>Splashscreen Example</title>
+
+ <script type="text/javascript" charset="utf-8" src="cordova-3.0.0.js"></script>
+ <script type="text/javascript" charset="utf-8">
+
+ // Wait for device API libraries to load
+ //
+ document.addEventListener("deviceready", onDeviceReady, false);
+
+ // device APIs are available
+ //
+ function onDeviceReady() {
+ navigator.splashscreen.hide();
+ }
+
+ </script>
+ </head>
+ <body>
+ <h1>Example</h1>
+ </body>
+ </html>
+
+iOS Quirk
+------------
+
+The `config.xml` file's `AutoHideSplashScreen` setting must be
+`false`. To delay hiding the splash screen for two seconds, add a
+timer such as the following in the `deviceready` event handler:
+
+ setTimeout(function() {
+ navigator.splashscreen.hide();
+ }, 2000);
http://git-wip-us.apache.org/repos/asf/cordova-docs/blob/17ffa3e5/docs/en/3.0.0rc1/cordova/splashscreen/splashscreen.md
----------------------------------------------------------------------
diff --git a/docs/en/3.0.0rc1/cordova/splashscreen/splashscreen.md b/docs/en/3.0.0rc1/cordova/splashscreen/splashscreen.md
new file mode 100644
index 0000000..c2cc060
--- /dev/null
+++ b/docs/en/3.0.0rc1/cordova/splashscreen/splashscreen.md
@@ -0,0 +1,81 @@
+---
+license: Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+---
+
+Splashscreen
+==========
+
+> Displays and hides the application's splash screen.
+
+Methods
+-------
+
+- splashscreen.show
+- splashscreen.hide
+
+Permissions
+-----------
+
+### Android
+
+#### app/res/xml/config.xml
+
+ <plugin name="SplashScreen" value="org.apache.cordova.SplashScreen"/>
+
+### iOS
+
+#### config.xml
+
+ <plugin name="SplashScreen" value="CDVSplashScreen" />
+
+Setup
+-----
+
+### Android
+
+1. Copy the splash screen image into the Android project's `res/drawable` directory. The size for each image should be:
+
+ - xlarge (xhdpi): at least 960 × 720
+ - large (hdpi): at least 640 × 480
+ - medium (mdpi): at least 470 × 320
+ - small (ldpi): at least 426 × 320
+
+ You should use a [9-patch image](https://developer.android.com/tools/help/draw9patch.html) for your splash screen.
+
+2. In the `onCreate` method of the class that extends `DroidGap`, add the following two lines:
+
+ super.setIntegerProperty("splashscreen", R.drawable.splash);
+ super.loadUrl(Config.getStartUrl(), 10000);
+
+ The first line sets the image to display as the splashscreen. If you name your image anything other than `splash.png`, you need to modify this line.
+ The second line is the normal `super.loadUrl` line, but it has a second parameter that specifies a timeout value for the splash screen. In this example the splash screen displays for 10 seconds. To dismiss the splash screen once the app receives the `deviceready` event, call the `navigator.splashscreen.hide()` method.
+
+### iOS
+
+Copy your splash screen images into the iOS project's
+`Resources/splash` directory. Only add the images for the devices you
+want to support, such as iPad or iPhone. The size of each image
+should be:
+
+- Default-568h@2x~iphone.png (640x1136 pixels)
+- Default-Landscape@2x~ipad.png (2048x1496 pixels)
+- Default-Landscape~ipad.png (1024x748 pixels)
+- Default-Portrait@2x~ipad.png (1536x2008 pixels)
+- Default-Portrait~ipad.png (768x1004 pixels)
+- Default@2x~iphone.png (640x960 pixels)
+- Default~iphone.png (320x480 pixels)
http://git-wip-us.apache.org/repos/asf/cordova-docs/blob/17ffa3e5/docs/en/3.0.0rc1/cordova/splashscreen/splashscreen.show.md
----------------------------------------------------------------------
diff --git a/docs/en/3.0.0rc1/cordova/splashscreen/splashscreen.show.md b/docs/en/3.0.0rc1/cordova/splashscreen/splashscreen.show.md
new file mode 100644
index 0000000..f4f4d8a
--- /dev/null
+++ b/docs/en/3.0.0rc1/cordova/splashscreen/splashscreen.show.md
@@ -0,0 +1,69 @@
+---
+license: Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+---
+
+splashscreen.show
+===============
+
+Displays the splash screen.
+
+ navigator.splashscreen.show();
+
+Description
+-----------
+
+This method displays the application's splash screen.
+
+Supported Platforms
+-------------------
+
+- Android
+- iOS
+
+Quick Example
+-------------
+
+ navigator.splashscreen.show();
+
+Full Example
+------------
+
+ <!DOCTYPE html>
+ <html>
+ <head>
+ <title>Splashscreen Example</title>
+
+ <script type="text/javascript" charset="utf-8" src="cordova-3.0.0.js"></script>
+ <script type="text/javascript" charset="utf-8">
+
+ // Wait for device API libraries to load
+ //
+ document.addEventListener("deviceready", onDeviceReady, false);
+
+ // device APIs are available
+ //
+ function onDeviceReady() {
+ navigator.splashscreen.show();
+ }
+
+ </script>
+ </head>
+ <body>
+ <h1>Example</h1>
+ </body>
+ </html>
http://git-wip-us.apache.org/repos/asf/cordova-docs/blob/17ffa3e5/docs/en/3.0.0rc1/cordova/storage/database/database.md
----------------------------------------------------------------------
diff --git a/docs/en/3.0.0rc1/cordova/storage/database/database.md b/docs/en/3.0.0rc1/cordova/storage/database/database.md
new file mode 100644
index 0000000..97b3ffd
--- /dev/null
+++ b/docs/en/3.0.0rc1/cordova/storage/database/database.md
@@ -0,0 +1,119 @@
+---
+license: Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+---
+
+Database
+=======
+
+Provides access to an SQL database.
+
+Methods
+-------
+
+- __transaction__: Runs a database transaction.
+- __changeVersion__: Allows scripts to automatically verify the version number and change it when updating a schema.
+
+Details
+-------
+
+The `window.openDatabase()` method returns a `Database` object.
+
+Supported Platforms
+-------------------
+
+- Android
+- BlackBerry WebWorks (OS 6.0 and higher)
+- iOS
+- Tizen
+
+Transaction Quick Example
+------------------
+ function populateDB(tx) {
+ tx.executeSql('DROP TABLE IF EXISTS DEMO');
+ tx.executeSql('CREATE TABLE IF NOT EXISTS DEMO (id unique, data)');
+ tx.executeSql('INSERT INTO DEMO (id, data) VALUES (1, "First row")');
+ tx.executeSql('INSERT INTO DEMO (id, data) VALUES (2, "Second row")');
+ }
+
+ function errorCB(err) {
+ alert("Error processing SQL: "+err.code);
+ }
+
+ function successCB() {
+ alert("success!");
+ }
+
+ var db = window.openDatabase("Database", "1.0", "Cordova Demo", 200000);
+ db.transaction(populateDB, errorCB, successCB);
+
+Change Version Quick Example
+-------------------
+
+ var db = window.openDatabase("Database", "1.0", "Cordova Demo", 200000);
+ db.changeVersion("1.0", "1.1");
+
+Full Example
+------------
+
+ <!DOCTYPE html>
+ <html>
+ <head>
+ <title>Storage Example</title>
+
+ <script type="text/javascript" charset="utf-8" src="cordova-3.0.0.js"></script>
+ <script type="text/javascript" charset="utf-8">
+
+ // Wait for device API libraries to load
+ //
+ document.addEventListener("deviceready", onDeviceReady, false);
+
+ // device APIs are available
+ //
+ function onDeviceReady() {
+ var db = window.openDatabase("Database", "1.0", "Cordova Demo", 200000);
+ db.transaction(populateDB, errorCB, successCB);
+ }
+
+ // Populate the database
+ //
+ function populateDB(tx) {
+ tx.executeSql('DROP TABLE IF EXISTS DEMO');
+ tx.executeSql('CREATE TABLE IF NOT EXISTS DEMO (id unique, data)');
+ tx.executeSql('INSERT INTO DEMO (id, data) VALUES (1, "First row")');
+ tx.executeSql('INSERT INTO DEMO (id, data) VALUES (2, "Second row")');
+ }
+
+ // Transaction error callback
+ //
+ function errorCB(tx, err) {
+ alert("Error processing SQL: "+err);
+ }
+
+ // Transaction success callback
+ //
+ function successCB() {
+ alert("success!");
+ }
+
+ </script>
+ </head>
+ <body>
+ <h1>Example</h1>
+ <p>Database</p>
+ </body>
+ </html>
http://git-wip-us.apache.org/repos/asf/cordova-docs/blob/17ffa3e5/docs/en/3.0.0rc1/cordova/storage/localstorage/localstorage.md
----------------------------------------------------------------------
diff --git a/docs/en/3.0.0rc1/cordova/storage/localstorage/localstorage.md b/docs/en/3.0.0rc1/cordova/storage/localstorage/localstorage.md
new file mode 100644
index 0000000..9d36dd8
--- /dev/null
+++ b/docs/en/3.0.0rc1/cordova/storage/localstorage/localstorage.md
@@ -0,0 +1,122 @@
+---
+license: Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+---
+
+localStorage
+===============
+
+Provides access to a [W3C Storage interface](http://dev.w3.org/html5/webstorage/#the-localstorage-attribute)
+
+ var storage = window.localStorage;
+
+Methods
+-------
+
+- __key__: Returns the name of the key at the specified position.
+- __getItem__: Returns the item identified by the specified key.
+- __setItem__: Assigns a keyed item's value.
+- __removeItem__: Removes the item identified by the specified key.
+- __clear__: Removes all of the key/value pairs.
+
+Details
+-----------
+
+The `window.localStorage` interface is based on the W3C Web Storage
+interface. An app can use it to save persistent data using key-value
+pairs. The `window.sessionStorage` interface works the same way, but
+all data is cleared each time the app closes.
+
+Supported Platforms
+-------------------
+
+- Android
+- BlackBerry WebWorks (OS 6.0 and higher)
+- iOS
+- Tizen
+- Windows Phone 7 and 8
+
+Key Quick Example
+-------------
+
+ var keyName = window.localStorage.key(0);
+
+Set Item Quick Example
+-------------
+
+ window.localStorage.setItem("key", "value");
+
+Get Item Quick Example
+-------------
+
+ var value = window.localStorage.getItem("key");
+ // value is now equal to "value"
+
+Remove Item Quick Example
+-------------
+
+ window.localStorage.removeItem("key");
+
+Clear Quick Example
+-------------
+
+ window.localStorage.clear();
+
+Full Example
+------------
+
+ <!DOCTYPE html>
+ <html>
+ <head>
+ <title>Storage Example</title>
+
+ <script type="text/javascript" charset="utf-8" src="cordova-3.0.0.js"></script>
+ <script type="text/javascript" charset="utf-8">
+
+ // Wait for device API libraries to load
+ //
+ document.addEventListener("deviceready", onDeviceReady, false);
+
+ // device APIs are available
+ //
+ function onDeviceReady() {
+ window.localStorage.setItem("key", "value");
+ var keyname = window.localStorage.key(i);
+ // keyname is now equal to "key"
+ var value = window.localStorage.getItem("key");
+ // value is now equal to "value"
+ window.localStorage.removeItem("key");
+ window.localStorage.setItem("key2", "value2");
+ window.localStorage.clear();
+ // localStorage is now empty
+ }
+
+ </script>
+ </head>
+ <body>
+ <h1>Example</h1>
+ <p>localStorage</p>
+ </body>
+ </html>
+
+Windows Phone 7 Quirks
+-------------
+
+Dot notation is _not_ available on Windows Phone 7. Be sure to use
+`setItem` or `getItem`, rather than accessing keys directly from the
+storage object, such as `window.localStorage.someKey`.
+
http://git-wip-us.apache.org/repos/asf/cordova-docs/blob/17ffa3e5/docs/en/3.0.0rc1/cordova/storage/parameters/display_name.md
----------------------------------------------------------------------
diff --git a/docs/en/3.0.0rc1/cordova/storage/parameters/display_name.md b/docs/en/3.0.0rc1/cordova/storage/parameters/display_name.md
new file mode 100644
index 0000000..226a0c6
--- /dev/null
+++ b/docs/en/3.0.0rc1/cordova/storage/parameters/display_name.md
@@ -0,0 +1,23 @@
+---
+license: Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+---
+
+database_displayname
+==================
+
+The display name of the database.
http://git-wip-us.apache.org/repos/asf/cordova-docs/blob/17ffa3e5/docs/en/3.0.0rc1/cordova/storage/parameters/name.md
----------------------------------------------------------------------
diff --git a/docs/en/3.0.0rc1/cordova/storage/parameters/name.md b/docs/en/3.0.0rc1/cordova/storage/parameters/name.md
new file mode 100644
index 0000000..b1c6a85
--- /dev/null
+++ b/docs/en/3.0.0rc1/cordova/storage/parameters/name.md
@@ -0,0 +1,23 @@
+---
+license: Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+---
+
+database_name
+============
+
+The name of the database.