{ "id": "109656", "key": "TIMOB-13059", "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": "14162", "description": "Release 3.1.0", "name": "Release 3.1.0", "archived": true, "released": true, "releaseDate": "2013-04-16" } ], "resolution": { "id": "1", "description": "A fix for this issue is checked into the tree and tested.", "name": "Fixed" }, "resolutiondate": "2013-03-14T03:48:09.000+0000", "created": "2013-02-13T17:50:03.000+0000", "priority": null, "labels": [ "android", "qe-port", "regression", "webview" ], "versions": [], "issuelinks": [ { "id": "26687", "type": { "id": "10002", "name": "Duplicate", "inward": "is duplicated by", "outward": "duplicates" }, "inwardIssue": { "id": "110351", "key": "TIMOB-13145", "fields": { "summary": "iOS: Setting WebView HTML contents directly fails to load local JavaScript file on device", "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 } } } }, { "id": "25952", "type": { "id": "10003", "name": "Relates", "inward": "relates to", "outward": "relates to" }, "outwardIssue": { "id": "93365", "key": "TIMOB-9593", "fields": { "summary": "Android: Webview: Webview with HTML property having HTML content does not reload", "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": "ingo", "key": "ingo", "displayName": "Ingo Muschenetz", "active": true, "timeZone": "America/Los_Angeles" }, "updated": "2013-03-14T09:21:15.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": "10202", "name": "Android", "description": "Android Platform" } ], "description": "The following works on SDK 2.x and 3.0.0 on all platforms and on 3.0.2RC on iOS, but not on 3.0.2RC on Android:\r\n\r\n{code}\r\nTi.UI.setBackgroundColor('#000');\r\nvar win = Ti.UI.createWindow();\r\n\r\nvar wv = Ti.UI.createWebView({\r\n\thtml: '

This is an accented e character: è

'\r\n});\r\n\r\nwin.add(wv);\r\nwin.open();\r\n{code}\r\n\r\nThe defects are:\r\n1) the accented character displays as garbage\r\n2) the local image does not show at all (changing its path to \"/images/img.png\" does not work either) \r\n", "attachment": [], "flagged": false, "summary": "Android: WebView: remove requirement to set baseURL", "creator": { "name": "banzaimobile", "key": "banzaimobile", "displayName": "Banzai Mobile", "active": true, "timeZone": "Europe/Berlin" }, "subtasks": [], "reporter": { "name": "banzaimobile", "key": "banzaimobile", "displayName": "Banzai Mobile", "active": true, "timeZone": "Europe/Berlin" }, "environment": "mobilesdk-3.0.2.v20130207164659 (3.0.2 RC)\r\nAndroid device, 4.1.2", "comment": { "comments": [ { "id": "239006", "author": { "name": "banzaimobile", "key": "banzaimobile", "displayName": "Banzai Mobile", "active": true, "timeZone": "Europe/Berlin" }, "body": "I think this bug has not been given enough attention.\r\nEncoding issue can be solved by adding mimeType to a setHtml call, but I cannot find any way to show local images.\r\n\r\nIMHO, it is a showstopper and should have blocked release of 3.0.2GA\r\n\r\nCould somebody please at least find and publish a workaround for displaying local images in a webview on Android?\r\n", "updateAuthor": { "name": "banzaimobile", "key": "banzaimobile", "displayName": "Banzai Mobile", "active": true, "timeZone": "Europe/Berlin" }, "created": "2013-02-20T11:09:25.000+0000", "updated": "2013-02-20T11:09:25.000+0000" }, { "id": "239021", "author": { "name": "ingo", "key": "ingo", "displayName": "Ingo Muschenetz", "active": true, "timeZone": "America/Los_Angeles" }, "body": "@Banzai--can you see if adding a baseURL solves the issues with images? See the related ticket TIMOB-9593.", "updateAuthor": { "name": "ingo", "key": "ingo", "displayName": "Ingo Muschenetz", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2013-02-20T15:18:08.000+0000", "updated": "2013-02-20T15:18:34.000+0000" }, { "id": "239027", "author": { "name": "banzaimobile", "key": "banzaimobile", "displayName": "Banzai Mobile", "active": true, "timeZone": "Europe/Berlin" }, "body": "@Ingo:\r\n\r\nYes, setting the baseURL solves both problems (image and text encoding).\r\nThat's good, because now calling setHtml with BOTH baseURL AND mimeType makes the html appear as code instead of rendered.", "updateAuthor": { "name": "banzaimobile", "key": "banzaimobile", "displayName": "Banzai Mobile", "active": true, "timeZone": "Europe/Berlin" }, "created": "2013-02-20T16:02:48.000+0000", "updated": "2013-02-20T16:02:48.000+0000" }, { "id": "239028", "author": { "name": "ingo", "key": "ingo", "displayName": "Ingo Muschenetz", "active": true, "timeZone": "America/Los_Angeles" }, "body": "@Banzai. Great. So this was a change...where do you think the best place to advertise this is? Where would you have expected to find a note about this (and didn't)?", "updateAuthor": { "name": "ingo", "key": "ingo", "displayName": "Ingo Muschenetz", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2013-02-20T16:08:23.000+0000", "updated": "2013-02-20T16:08:23.000+0000" }, { "id": "239032", "author": { "name": "banzaimobile", "key": "banzaimobile", "displayName": "Banzai Mobile", "active": true, "timeZone": "Europe/Berlin" }, "body": "@Ingo: I'd mention it in the API docs for WebView, specifically under the html property and setHtml method.\r\nAnd of course in its own paragraph in the 3.0.2 release notes.", "updateAuthor": { "name": "banzaimobile", "key": "banzaimobile", "displayName": "Banzai Mobile", "active": true, "timeZone": "Europe/Berlin" }, "created": "2013-02-20T16:15:19.000+0000", "updated": "2013-02-20T16:15:19.000+0000" }, { "id": "239317", "author": { "name": "bigotilda", "key": "bigotilda", "displayName": "Nathan Nadeau", "active": true, "timeZone": "America/New_York" }, "body": "Yes this would be nice to be mentioned in the API docs, the 3.0.2 release notes, and also the WebView user guide page: http://docs.appcelerator.com/titanium/3.0/#!/guide/The_WebView_Component-section-29004918_TheWebViewComponent-UsingLocalWebContentwithWebView.\r\n\r\nNote I have added an informational post to the Q&A forums: http://developer.appcelerator.com/question/148638/notice-titanium-302-android-webview-not-loading-local-resource-files-properly-via-html-property", "updateAuthor": { "name": "bigotilda", "key": "bigotilda", "displayName": "Nathan Nadeau", "active": true, "timeZone": "America/New_York" }, "created": "2013-02-21T21:30:36.000+0000", "updated": "2013-02-21T21:30:36.000+0000" }, { "id": "242036", "author": { "name": "oromero", "key": "oromero", "displayName": "Olga Romero", "active": true, "timeZone": "America/Los_Angeles" }, "body": "I reproduced this issue with 3.0.2.GA\r\n\r\nDefects ARE GONE with:\r\nTitanium Studio, build: 3.0.3.201302201202\r\nTitanium SDK, build: 3.1.0.v20130312161655\r\nDevice:\r\nNexus7 Android version: 4.2", "updateAuthor": { "name": "oromero", "key": "oromero", "displayName": "Olga Romero", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2013-03-13T18:31:03.000+0000", "updated": "2013-03-13T18:31:23.000+0000" }, { "id": "242158", "author": { "name": "ingo", "key": "ingo", "displayName": "Ingo Muschenetz", "active": true, "timeZone": "America/Los_Angeles" }, "body": "This was fixed as a result of re-fixing TIMOB-9593.", "updateAuthor": { "name": "ingo", "key": "ingo", "displayName": "Ingo Muschenetz", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2013-03-14T03:48:09.000+0000", "updated": "2013-03-14T03:48:09.000+0000" }, { "id": "242197", "author": { "name": "sbhadauria", "key": "sbhadauria", "displayName": "Shyam Bhadauria", "active": true, "timeZone": "America/Los_Angeles" }, "body": "The local image is being shown now.\r\nEnvironment used for verification -\r\nTitanium SDK: 3.1.0.v20130311192922\r\nTitanium  Studio:3.0.2.201302151605\r\nDevice: Nexus 7 Android 4.1", "updateAuthor": { "name": "sbhadauria", "key": "sbhadauria", "displayName": "Shyam Bhadauria", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2013-03-14T09:21:15.000+0000", "updated": "2013-03-14T09:21:15.000+0000" } ], "maxResults": 9, "total": 9, "startAt": 0 } } }