Cordova/Phonegap iOS-如何启动应用程序&x27;外部文档文件夹中的s index.html

Cordova/Phonegap iOS-如何启动应用程序&x27;外部文档文件夹中的s index.html,ios,cordova,Ios,Cordova,我们正在尝试在不更新应用程序本身的情况下实现webapp资产的更新 我将资产下载到Documents/some/path/name文件夹,并尝试从此文件夹启动应用程序 但应用程序日志显示未找到../Documents/…/index.html 以下是我的代码示例: NSString *wwwFolderName = @"web"; if ([directoryList count] > 0) { NSArray *sortedDirectoryList = [directoryL

我们正在尝试在不更新应用程序本身的情况下实现webapp资产的更新

我将资产下载到Documents/some/path/name文件夹,并尝试从此文件夹启动应用程序

但应用程序日志显示未找到
../Documents/…/index.html

以下是我的代码示例:

NSString *wwwFolderName = @"web";

if ([directoryList count] > 0) {
    NSArray *sortedDirectoryList = [directoryList sortedArrayUsingSelector:@selector(compare:)];
    NSString *latestVersionFolder = [sortedDirectoryList objectAtIndex:([sortedDirectoryList count] - 1)];
    wwwFolderName = [appDirectory stringByAppendingPathComponent:latestVersionFolder];
}

// end of assets directory initialization


self.viewController = [[MainViewController alloc] init];
self.viewController.useSplashScreen = YES;
self.viewController.wwwFolderName = wwwFolderName;
self.viewController.startPage = @"index.html";
如何从文档的应用程序特定文件夹启动cordova应用程序

downloaded assets path: /var/mobile/Applications/{App-HASH}/Documents/revisions/123/ 下载的资产路径:/var/mobile/Applications/{App HASH}/Documents/revisions/123/ 这是Orgamizer日志显示的内容:

ERROR: Start Page at '/var/mobile/Applications/10E317FA-CD51-4DD1-A07D-3C69EB4C5342/Documents/appname/790/index.html' was not found. 错误:未找到位于“/var/mobile/Applications/10E317FA-CD51-4DD1-A07D-3C69EB4C5342/Documents/appname/790/index.html”的起始页。