[TIMOB-8384] MobileWeb: Ti.include fails from production server if path starts with forward slash
| GitHub Issue | n/a |
|---|---|
| Type | Bug |
| Priority | High |
| Status | Closed |
| Resolution | Invalid |
| Resolution Date | 2012-03-28T20:05:26.000+0000 |
| Affected Version/s | Release 2.0.0 |
| Fix Version/s | n/a |
| Components | MobileWeb |
| Labels | parity, qe-mw020912, regression |
| Reporter | Dustin Hyde |
| Assignee | Chris Barber |
| Created | 2012-03-28T17:39:46.000+0000 |
| Updated | 2013-05-01T20:10:11.000+0000 |
Description
Ti.include fails from production server if path starts with forward slash.
Log: 03-28 18:04:52.582: E/browser(10186): Console: Uncaught Error: Failed to load include "/scripts/file.js": 404 http://172.16.1.192/Test/:443
Works from browser deployment preview and emulator browser preview.
Regression.
Works in 1.8.2.
Parity.
Works on iOS and Android.
Steps to Reproduce:
1. Run project from server on device.
Expected Result:
Alert indicating file include.
Actual Result:
No alert. Console error.
Attachments
| File | Date | Size |
|---|---|---|
| Test.zip | 2012-03-28T17:39:46.000+0000 | 3120431 |
This works just fine when you host the site in the web root. If you put a mobile web app in a subdirectory, you need to use the correct full path "/Test/scripts/file.js" or a relative path "scripts/file.js". I will document this mobile web behavior.
Closing.