1

I generated a cordova xcode project with sencha cmd. But now I'm trying to run it, but I'm getting the whitelist rejection error, although I have already edited www/config.xml.

My phonegap version is 3.4.0-0.19.8.

Please tell me if you need more info. Thank you very much for your help!

enter image description here

ethanjyx
  • 1,970
  • 7
  • 28
  • 50
  • http://stackoverflow.com/questions/10795628/error-whitelist-rejection-in-phonegap try this – NextStep Mar 27 '14 at 04:59
  • Thanks James. I've read through the thread. For my version of PhoneGap, there is no Cordova.plist file. config.xml should be the right file to edit. – ethanjyx Mar 27 '14 at 05:15
  • In phonegap 3.4, hasn't config.xml moved to the root of the project (not www)? Just to be clear, what are you trying to do here? (in the xml you provided, you blacklist everything that's not phonegap.com) And have you rebuilt the project after changing config.xml? (as I see you're using xcode, changes outside the platforms/ios folder are ignored unless you build using the cli) – QuickFix Mar 27 '14 at 08:38
  • I can only find the config.xml under www. I built the app with Sencha Touch and have included several external javascript libraries, such as Facebook SDK. But they cannot be loaded because of the whitelist issue. So I'm testing by given all external origins access but it still does not work out. What do you mean by "build using the cli"? I cleaned the project in xcode after edits and rebuilt it. – ethanjyx Mar 27 '14 at 14:10

1 Answers1

0

Look for a copy of config.xml in the Staging group in the XCode project. As QuickFix suggested, you will need to run cordova build ios or cordova prepare ios command from your application directory. This will update the files located in the Staging group.

Jeff Martin
  • 550
  • 4
  • 12
  • What do you mean by staging group? – ethanjyx Mar 31 '14 at 14:15
  • There is a Staging group folder in your XCode project. If your project is created using the cordova CLI tools you will have folders [AppName]/www and [AppName]/platforms/ios/www. The XCode project is using the files from [AppName]/platforms/ios/www. I assume that Sencha CMD creates the project the same way as the cordova CLI tools. – Jeff Martin Mar 31 '14 at 15:22