You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by sh...@apache.org on 2013/01/31 23:47:34 UTC

docs commit: Added iOS 2.3.0 to 2.4.0 Upgrading doc

Updated Branches:
  refs/heads/master 76db22536 -> b8e58c5d3


Added iOS 2.3.0 to 2.4.0 Upgrading doc


Project: http://git-wip-us.apache.org/repos/asf/cordova-docs/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-docs/commit/b8e58c5d
Tree: http://git-wip-us.apache.org/repos/asf/cordova-docs/tree/b8e58c5d
Diff: http://git-wip-us.apache.org/repos/asf/cordova-docs/diff/b8e58c5d

Branch: refs/heads/master
Commit: b8e58c5d3758adbf775cf77b801e79f3afeea36a
Parents: 76db225
Author: Shazron Abdullah <sh...@apache.org>
Authored: Thu Jan 31 14:47:27 2013 -0800
Committer: Shazron Abdullah <sh...@apache.org>
Committed: Thu Jan 31 14:47:27 2013 -0800

----------------------------------------------------------------------
 docs/en/edge/guide/upgrading/ios/index.md |   27 ++++++++++++++---------
 1 files changed, 16 insertions(+), 11 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-docs/blob/b8e58c5d/docs/en/edge/guide/upgrading/ios/index.md
----------------------------------------------------------------------
diff --git a/docs/en/edge/guide/upgrading/ios/index.md b/docs/en/edge/guide/upgrading/ios/index.md
index a16b2db..a1c3d6b 100644
--- a/docs/en/edge/guide/upgrading/ios/index.md
+++ b/docs/en/edge/guide/upgrading/ios/index.md
@@ -22,6 +22,18 @@ Upgrading Cordova iOS
 
 Please note that **Xcode 4.5 is required**. To submit to the Apple App Store, you must use the latest shipped version of the iOS SDK, which is iOS 6. The iOS 6 SDK requires Xcode 4.5.
 
+## Upgrading Cordova 2.3.0 projects to 2.4.0 ##
+
+1. **Download and extract the Cordova 2.4.0 source** to a **permanent folder location** on your hard drive (say to ~/Documents/Cordova-2.4.0)
+2. **Quit Xcode** if it is running.
+3. **Navigate** to the directory where you put the downloaded source above, using **Terminal.app**.
+4. [**Create a new project**](guide_command-line_index.md.html#Command-Line%20Usage_ios) from the command-line tools - you will have to grab the assets from this new project
+5. **Copy** the **www/cordova-2.4.0.js** file from the new project into your **www** folder, and delete your **www/cordova-2.3.0.js** file
+6. **Update** the Cordova script reference in your **www/index.html** file (and any other files that contain the script reference) to point to the new **cordova-2.4.0.js** file
+7. Update (or replace, if you never changed the file) your **MainViewController.m** according to the one from the new project.
+8. Delete your **"cordova"** folder, and copy the **"cordova"** folder from the new project into your project's root folder **(in 2.4.0, this has fixed scripts)** 
+9. Delete your **"CordovaLib"** folder, and copy the **"CordovaLib"** folder from the new project into your project's root folder
+
 ## Upgrading Cordova 2.2.0 projects to 2.3.0 ##
 
 1. **Download and extract the Cordova 2.3.0 source** to a **permanent folder location** on your hard drive (say to ~/Documents/Cordova-2.3.0)
@@ -33,20 +45,13 @@ Please note that **Xcode 4.5 is required**. To submit to the Apple App Store, yo
 7. Update (or replace, if you never changed the file) your **MainViewController.m** according to the one from the new project.
 8. Delete your **"cordova"** folder, and copy the **"cordova"** folder from the new project into your project's root folder **(in 2.3.0, this has new scripts)** 
 9. Delete your **"CordovaLib"** folder, and copy the **"CordovaLib"** folder from the new project into your project's root folder
-10. Next, update your CordovaLib sub-project reference.
-    1. Launch **Terminal.app**
-    2. Go to the location where you installed Cordova **(see Step 1)**, in the **bin** sub-folder
-    3. Run the script below where the first parameter is the path to your project's **.xcodeproj** file:
-    
-        `update_cordova_subproject path/to/your/project/xcodeproj`
-
-11. Convert your **Cordova.plist** file to **config.xml**, by running the script **bin/cordova\_plist\_to\_config\_xml** on your project file.
-12. Add the InAppBrowser plugin to your **config.xml**, by adding this tag under **&lt;cordova&gt;&lt;plugins&gt;**:
+10. Convert your **Cordova.plist** file to **config.xml**, by running the script **bin/cordova\_plist\_to\_config\_xml** on your project file.
+11. Add the InAppBrowser plugin to your **config.xml**, by adding this tag under **&lt;cordova&gt;&lt;plugins&gt;**:
 
         <plugin name="InAppBrowser" value="CDVInAppBrowser" />
-13. Note that Objective-C plugins are **not** whitelisted anymore. To whitelist your connections with the app whitelist, you will need to set the “User-Agent” header of the connection to the same user-agent as the main Cordova WebView. 
+12. Note that Objective-C plugins are **not** whitelisted anymore. To whitelist your connections with the app whitelist, you will need to set the “User-Agent” header of the connection to the same user-agent as the main Cordova WebView. 
 You can get this by accessing the **userAgent** property off the main view-controller. The main view-controller (CDVViewController) also has a **URLisAllowed** method for you to check whether a URL will pass the whitelist.        
-14. Device API changes: 
+13. Device API changes: 
     * For iOS, device.platform used to return “iPhone”, “iPad” or “iPod Touch” — now it returns (correctly) “iOS”. 
     * For iOS, device.name (now deprecated for all platforms) used to return the name of the user’s device (e.g ‘Shazron’s iPhone 5′) — now it returns what device.platform used to return: ”iPhone”, “iPad” or “iPod Touch”.  
     * For all platforms, there is a new property called device.model — this returns the specific device model, e.g “iPad2,5″ (for other platforms, this returns what device.name used to return).