[TIMOB-1959] Ti.include can not use absolute paths in iOS
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | Trivial |
Status | Closed |
Resolution | Duplicate |
Resolution Date | 2011-04-15T03:06:32.000+0000 |
Affected Version/s | n/a |
Fix Version/s | n/a |
Components | iOS |
Labels | n/a |
Reporter | eddiemonge |
Assignee | Reggie Seagraves |
Created | 2011-04-15T03:06:31.000+0000 |
Updated | 2017-03-09T21:31:28.000+0000 |
Description
There doesn't seem to be anyway to do an absolute path using Ti.include in iOS. I've tried the following with various modifications of each with no success:
Ti.include('/windows/menu.js');
Ti.include('app://windows/menu.js');
Ti.include(Ti.fileSystem.resourcesDirectory+'/windows/menu.js');
[ERROR] error loading path: file://localhost/Users/eddie/Library/Application%20Support/iPhone%20Simulator/4.1/Applications/CE687F4B-F7E7-4543-8217-898478D9B6B0/Manatee.app//Users/eddie/Dropbox/Mobile%20Apps/Manatee/Resources/windows/menu.js, Error Domain=NSCocoaErrorDomain Code=260 "The operation couldn’t be completed. (Cocoa error 260.)" UserInfo=0x7e34260 {NSFilePath=/Users/eddie/Library/Application Support/iPhone Simulator/4.1/Applications/CE687F4B-F7E7-4543-8217-898478D9B6B0/Manatee.app//Users/eddie/Dropbox/Mobile Apps/Manatee/Resources/windows/menu.js
+1
There really needs to be some way to include a file via an absolute paths in Titanium. This limitation is forcing me to put every single window in the root directory, which is non-ideal in many cases.
Also here: https://appcelerator.lighthouseapp.com/projects/32238/tickets/2585-include-paths-for-iphone-and-android-are-not-based-on-the-same-starting-point"> https://appcelerator.lighthouseapp.com/projects/32238/tickets/2585-...
I'm also waiting on this...
Dupe of #2585, as per above.
Closing ticket as duplicate.