New webview does not load form.
Reported by
mike.l.h...@gmail.com,
Sep 29 2017
|
|||||||
Issue description
THIS TEMPLATE IS FOR FILING BUGS ON THE ANDROID SYSTEM WEBVIEW. GENERAL WEB
BUGS SHOULD BE FILED USING A DIFFERENT TEMPLATE!
Device name: Moto Z Play, and many others
Android version: 7.1
WebView version (from system settings -> Apps -> Android System WebView): 61.0.3163.98
Application: com.luvcrew.cwa.free
Application version: 24008
URLs (if applicable):
Steps to reproduce:
(1) You can't reproduce because you can't log in to the app's web site.
The web site (not developed by me) opens a new window, names it and makes it the target of a form submission. This worked fine until the latest update.
Here is the general idea:
javascript
-------------
form.target = "myWindow";
window.open( "//pages/wait" , "myWindow" , features );
// app handles WebChromeClient.onCreateWindow( ... )
form.submit();
// new window does not navigate (neither GET nor POST) to the form's action url
Expected result:
New window loads HTML resource.
Actual result:
New window calls WebViewClient.onPageStarted(...) but does not load web page.
My revised code cat sense a lack of activity and call WebView.reload(), but this does not work for POST requests even after overriding WebViewClient.onFormResubmission(...) with a call to resend.sendToTarget().
,
Sep 30 2017
Yes. Users started having problems with the latest non-beta update in the last week. I am able to get some functionality using a delayed WebView.reload(), but this does not work for POST requests. It may be a separate bug that reload does not work or even trigger WebViewClient.onFormResubmission(...) for POST requests. WebView.reload seems to do a GET on the original URL.
,
Sep 30 2017
that would be between m60 and m61 then post requests probably shouldn't be reloaded, that would be like submitting a form twice, which is generally undesired. chrome has a warning dialog, which I'm not sure is plumbed up to apps in webview
,
Sep 30 2017
It is plumbed in, in the form of the WebViewClient.onFormResubmission callback. The default behavior is to NOT resend the POST data, but the app has the option of calling either sender.sendToTarget() or dontResend.sendToTarget() to make its intent known.
,
Oct 25 2017
@mike.l.hatfield: Thanks for the report!! Could you please help us with the sample app or .apk file where, you're seeing the issue? Thanks!!
,
Oct 25 2017
,
Oct 27 2017
Yes, I will. My browser app accesses a restricted website, so I can't demonstrate there. I also have pushed out a hack that reloads the page after a period of inactivity, so my users are back to 'normal.' I'll have to make a sample app that demonstrates the same behavior. This will take a little time, but I am motivated to get this fixed and keep my Android-faithful coworkers happy (which is the only reward I get for this project - no $$ at all). I'll reply again to this email when I have something to work with... Mike
,
Oct 27 2017
Thank you for providing more feedback. Adding requester "sandeepkumars@chromium.org" to the cc list and removing "Needs-Feedback" label. For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
,
Oct 27 2017
re-adding needs-feedback until we get the actual APK. Thanks!
,
Dec 5 2017
@mike.l.hatfield -- Could you please provide an apk or any update with the latest behavior which would help us to triage the issue further. Thanks in Advance.
,
Jan 9 2018
Closing this issue as WontFix, due to lack of response from reporter. @mike.l.hatfield: Please feel free to log a new issue if you face any? Thanks!!
,
Jan 31 2018
Thanks. I made an APK that demonstrates the problem, just in time for WebView 64 to come out and fix the problem. If you're interested in seeing how older versions have troubles, I can put the demo app on github or something. |
|||||||
►
Sign in to add a comment |
|||||||
Comment 1 by boliu@chromium.org
, Sep 30 2017