{
"id": "160885",
"key": "TIMOB-23479",
"fields": {
"issuetype": {
"id": "1",
"description": "A problem which impairs or prevents the functions of the product.",
"name": "Bug",
"subtask": false
},
"project": {
"id": "10153",
"key": "TIMOB",
"name": "Titanium SDK/CLI",
"projectCategory": {
"id": "10100",
"description": "Titanium and related SDKs used in application development",
"name": "Client"
}
},
"fixVersions": [
{
"id": "16980",
"description": "New V8",
"name": "Release 6.0.0",
"archived": false,
"released": true,
"releaseDate": "2016-11-15"
}
],
"resolution": {
"id": "1",
"description": "A fix for this issue is checked into the tree and tested.",
"name": "Fixed"
},
"resolutiondate": "2016-06-30T07:24:45.000+0000",
"created": "2016-06-07T07:37:43.000+0000",
"priority": {
"name": "None",
"id": "6"
},
"labels": [],
"versions": [
{
"id": "17707",
"name": "Release 5.3.0",
"archived": false,
"released": true,
"releaseDate": "2016-06-04"
}
],
"issuelinks": [
{
"id": "52024",
"type": {
"id": "10003",
"name": "Relates",
"inward": "relates to",
"outward": "relates to"
},
"outwardIssue": {
"id": "161040",
"key": "TIMOB-23503",
"fields": {
"summary": "Windows: WebView local script doesn't work for hyperlink ",
"status": {
"description": "The issue is considered finished, the resolution is correct. Issues which are closed can be reopened.",
"name": "Closed",
"id": "6",
"statusCategory": {
"id": 3,
"key": "done",
"colorName": "green",
"name": "Done"
}
},
"priority": {
"name": "High",
"id": "2"
},
"issuetype": {
"id": "1",
"description": "A problem which impairs or prevents the functions of the product.",
"name": "Bug",
"subtask": false
}
}
}
}
],
"assignee": {
"name": "kiguchi",
"key": "kota",
"displayName": "Kota Iguchi",
"active": false,
"timeZone": "America/Los_Angeles"
},
"updated": "2016-10-14T17:01:14.000+0000",
"status": {
"description": "The issue is considered finished, the resolution is correct. Issues which are closed can be reopened.",
"name": "Closed",
"id": "6",
"statusCategory": {
"id": 3,
"key": "done",
"colorName": "green",
"name": "Done"
}
},
"components": [
{
"id": "12642",
"name": "Windows",
"description": "Windows authoring support"
}
],
"description": "Hello, I have a local webpage which I want to open in webview. This works fine, But, I have an image, inside my webpage, which does not show when the webview opens.\r\n\r\nI am putting my html and image file in assets directory, which is not working. I even tried to put the files in lib directory, which also does not work. \r\n\r\nI also tried with hyperlink inside my webpage, which will open another local webpage. I can see the hyperlink in webview but clicking on it does not open my webpage. \r\n\r\nI am testing for both alloy and classic project. I am using SDK 5.2.2.GA and 5.3.0.GA.\r\n{code}\r\nvar webview = Titanium.UI.createWebView({url:'logging.html});\r\n var window = Titanium.UI.createWindow();\r\n window.add(webview);\r\n window.open({modal:true});\r\n{code}\r\n{code}\r\n\r\n \r\n \r\n \r\n\r\n{code}\r\n\r\nI have tested in android without any problem. Thanks.",
"attachment": [
{
"id": "59509",
"filename": "logging.html",
"author": {
"name": "sdarda",
"key": "sdarda",
"displayName": "Sharif AbuDarda",
"active": false,
"timeZone": "Asia/Dhaka"
},
"created": "2016-06-07T07:31:25.000+0000",
"size": 165,
"mimeType": "text/html"
},
{
"id": "59510",
"filename": "sample.jpg",
"author": {
"name": "sdarda",
"key": "sdarda",
"displayName": "Sharif AbuDarda",
"active": false,
"timeZone": "Asia/Dhaka"
},
"created": "2016-06-07T07:31:29.000+0000",
"size": 325935,
"mimeType": "image/jpeg"
}
],
"flagged": false,
"summary": "Windows: Local webview does not show any images, or opens other files.",
"creator": {
"name": "sdarda",
"key": "sdarda",
"displayName": "Sharif AbuDarda",
"active": false,
"timeZone": "Asia/Dhaka"
},
"subtasks": [],
"reporter": {
"name": "sdarda",
"key": "sdarda",
"displayName": "Sharif AbuDarda",
"active": false,
"timeZone": "Asia/Dhaka"
},
"environment": null,
"closedSprints": [
{
"id": 649,
"state": "closed",
"name": "2016 Sprint 13 SDK",
"startDate": "2016-06-18T00:25:17.303Z",
"endDate": "2016-07-02T00:25:00.000Z",
"completeDate": "2016-07-04T04:25:16.889Z",
"originBoardId": 114
}
],
"comment": {
"comments": [
{
"id": "387808",
"author": {
"name": "flat-8-kiki",
"key": "flat-8-kiki",
"displayName": "Riyoko H",
"active": true,
"timeZone": "Asia/Tokyo"
},
"body": "> I am using SDK 5.2.2.GA and 5.3.0.GA.\r\n\r\nHi, These issues occur after 5.3.0.GA. :HTML can't display an image. hyperlink does not work.\r\nAnd it not occur in 5.2.2.GA in my environment.",
"updateAuthor": {
"name": "flat-8-kiki",
"key": "flat-8-kiki",
"displayName": "Riyoko H",
"active": true,
"timeZone": "Asia/Tokyo"
},
"created": "2016-06-08T04:21:13.000+0000",
"updated": "2016-06-08T04:21:13.000+0000"
},
{
"id": "387926",
"author": {
"name": "kiguchi",
"key": "kota",
"displayName": "Kota Iguchi",
"active": false,
"timeZone": "America/Los_Angeles"
},
"body": "Local links are not working because Windows Phone WebView (browser controls) doesn't allow local link unless you explicitly specify {{ms-appx-web://}}. \r\n\r\nI would suggest use of following workaround:\r\n\r\nFor images:\r\n\r\n{code:xml}\r\n\r\n{code}\r\n\r\nFor local links:\r\n\r\n{code:xml}\r\n\r\n{code}\r\n",
"updateAuthor": {
"name": "kiguchi",
"key": "kota",
"displayName": "Kota Iguchi",
"active": false,
"timeZone": "America/Los_Angeles"
},
"created": "2016-06-09T07:48:22.000+0000",
"updated": "2016-06-09T07:48:22.000+0000"
},
{
"id": "388012",
"author": {
"name": "flat-8-kiki",
"key": "flat-8-kiki",
"displayName": "Riyoko H",
"active": true,
"timeZone": "Asia/Tokyo"
},
"body": "Thank you for comment.\r\n\r\nI tried to change the html, it is shown jpeg file correctly. \r\nand I confirmed that HTML can call hyperlink.\r\n\r\nHowever, I'd like to put logging.html into \"ms-appdata:///local/\".\r\nand I can't access logging.html at \"ms-appdata:///local/\".\r\n\r\nHow can I access logging.html within \"ms-appdata:///local/\"?\r\n",
"updateAuthor": {
"name": "flat-8-kiki",
"key": "flat-8-kiki",
"displayName": "Riyoko H",
"active": true,
"timeZone": "Asia/Tokyo"
},
"created": "2016-06-10T06:51:24.000+0000",
"updated": "2016-06-10T06:51:24.000+0000"
},
{
"id": "388166",
"author": {
"name": "kiguchi",
"key": "kota",
"displayName": "Kota Iguchi",
"active": false,
"timeZone": "America/Los_Angeles"
},
"body": "Looks like Windows WebView accepts local content only from sub directory of the root url where you {{WebView.Navigate}} (in Titanium it's {{WebView.url}} property). In addition to that, the file content in {{ms-appdata}} should be placed under subdirectory of local folder:\r\n\r\n{quote}\r\nThe WebView support for this scheme requires you to place your content in a subfolder under the local or temporary folder. This enables navigation to URIs such as ms-appdata:///local/folder/file.html and ms-appdata:///temp/folder/file.html\r\n{quote}\r\n\r\n (See https://msdn.microsoft.com/library/windows/apps/windows.ui.xaml.controls.webview.aspx)\r\n\r\nSo This mean you may need to copy index content to application data directory and navigate to {{ms-appdata:///local/xxx/index.html}} in order to load content under {{ms-appdata:///local/xxx/}}. Let say you have index content in application resource directory:\r\n\r\n{code}\r\nfunction go() {\r\n var from = Ti.Filesystem.getFile(Ti.Filesystem.resourcesDirectory, 'index.html');\r\n // todo: You'll need to create \"webroot\" subdirectory in this case before copying if it doesn't exist\r\n var to = Ti.Filesystem.applicationDataDirectory + 'webroot' + Ti.Filesystem.separator + 'index.html';\r\n from.copy(to);\r\n\r\n webview.url = 'ms-appdata:///local/webroot/index.html';\r\n}\r\n{code}\r\n\r\nFYI http://wakiama.hatenadiary.jp/entry/2016/02/20/120728 (Japanese)\r\n\r\n\r\n",
"updateAuthor": {
"name": "kiguchi",
"key": "kota",
"displayName": "Kota Iguchi",
"active": false,
"timeZone": "America/Los_Angeles"
},
"created": "2016-06-13T03:13:50.000+0000",
"updated": "2016-06-13T03:13:50.000+0000"
},
{
"id": "388189",
"author": {
"name": "flat-8-kiki",
"key": "flat-8-kiki",
"displayName": "Riyoko H",
"active": true,
"timeZone": "Asia/Tokyo"
},
"body": "Thanks for your advice.\r\n\r\nI create new folder that named \"webroot\" in applicationDataDirectory,\r\nand copy HTML resourse file (ex.logging.html, sample.jpg) from ResourceDirectory.\r\nthen, I can display logging.html where in \"ms-appdata:///local/webroot/\".\r\n\r\nbut, \"ms-appdata:///local/webroot/logging.html\" can not display the referenced file:\"ms-appdata:///local/webroot/sample1.jpg\",\"ms-appdata:///local/webroot/logging2.html\".\r\n\r\nI tried these HTML tags for display to \"ms-appdata:///local/webroot/sample1.jpg\". but \"ms-appdata:///local/webroot/sample1.jpg\" was not displayed.\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\nidentically, I tried hyperlink, but these tags not worked.\r\n\r\n logging2.html\r\n logging2.html\r\n logging2.html\r\n logging2.html\r\n logging2.html\r\n logging2.html\r\n logging2.html\r\n\r\nHow can I call \"ms-appdata:///local/webroot/sample1.jpg\" and \"ms-appdata:///local/webroot/logging2.html\" from \"ms-appdata:///local/webroot/logging.html\"?\r\n\r\n",
"updateAuthor": {
"name": "flat-8-kiki",
"key": "flat-8-kiki",
"displayName": "Riyoko H",
"active": true,
"timeZone": "Asia/Tokyo"
},
"created": "2016-06-13T08:07:14.000+0000",
"updated": "2016-06-13T08:07:14.000+0000"
},
{
"id": "388284",
"author": {
"name": "kiguchi",
"key": "kota",
"displayName": "Kota Iguchi",
"active": false,
"timeZone": "America/Los_Angeles"
},
"body": "I am able to reproduce the issue too. According to [this blog|http://wakiama.hatenadiary.jp/entry/2016/02/20/120728] relative link for {{ms-appdata}} should work, but it does not for me. Investigating.",
"updateAuthor": {
"name": "kiguchi",
"key": "kota",
"displayName": "Kota Iguchi",
"active": false,
"timeZone": "America/Los_Angeles"
},
"created": "2016-06-14T12:53:23.000+0000",
"updated": "2016-06-14T12:53:23.000+0000"
},
{
"id": "388920",
"author": {
"name": "kiguchi",
"key": "kota",
"displayName": "Kota Iguchi",
"active": false,
"timeZone": "America/Los_Angeles"
},
"body": "https://github.com/appcelerator/titanium_mobile_windows/pull/749",
"updateAuthor": {
"name": "kiguchi",
"key": "kota",
"displayName": "Kota Iguchi",
"active": false,
"timeZone": "America/Los_Angeles"
},
"created": "2016-06-23T12:52:28.000+0000",
"updated": "2016-06-23T12:52:28.000+0000"
},
{
"id": "398986",
"author": {
"name": "eharris",
"key": "eharris",
"displayName": "Ewan Harris",
"active": true,
"timeZone": "Europe/Dublin"
},
"body": "Verified using:\r\n\r\nOS: Microsoft Windows 10 Pro 10.0.14393\r\nAppc core: 6.0.0-58\r\nAppc NPM: 4.2.8-7\r\nTi SDK: 6.0.0.v20161013072802\r\nAppc Studio: 4.8.0.201610060953\r\nLumia 550 10.0\r\n\r\nLocal webview now shows images stored locally on the device\r\n\r\nClosing ticket",
"updateAuthor": {
"name": "eharris",
"key": "eharris",
"displayName": "Ewan Harris",
"active": true,
"timeZone": "Europe/Dublin"
},
"created": "2016-10-14T17:01:10.000+0000",
"updated": "2016-10-14T17:01:10.000+0000"
}
],
"maxResults": 9,
"total": 9,
"startAt": 0
}
}
}