Comments (4)
COREWEBVIEW2_WEB_RESOURCE_REQUEST_SOURCE_KINDS_ALL includes COREWEBVIEW2_WEB_RESOURCE_REQUEST_SOURCE_KINDS_DOCUMENT and the WebView2 documentation states that it should include requests from the main page including dedicated workers and iframes.
I would try this to see if the URL is filtered :
WVBrowser1.AddWebResourceRequestedFilterWithRequestSourceKinds('*', COREWEBVIEW2_WEB_RESOURCE_CONTEXT_ALL, COREWEBVIEW2_WEB_RESOURCE_REQUEST_SOURCE_KINDS_ALL);
If the browser doesn't filter the URL you need with the last code I would report this to the WebView2 project :
https://github.com/MicrosoftEdge/WebView2Feedback/issues
from webview4delphi.
I forgot the asterisk in the AddWebResourceRequestedFilterWithRequestSourceKinds call.
You can test this in the MiniBrowser demo.
from webview4delphi.
COREWEBVIEW2_WEB_RESOURCE_REQUEST_SOURCE_KINDS_ALL includes COREWEBVIEW2_WEB_RESOURCE_REQUEST_SOURCE_KINDS_DOCUMENT and the WebView2 documentation states that it should include requests from the main page including dedicated workers and iframes.
I would try this to see if the URL is filtered :
WVBrowser1.AddWebResourceRequestedFilterWithRequestSourceKinds('*', COREWEBVIEW2_WEB_RESOURCE_CONTEXT_ALL, COREWEBVIEW2_WEB_RESOURCE_REQUEST_SOURCE_KINDS_ALL);
If the browser doesn't filter the URL you need with the last code I would report this to the WebView2 project : https://github.com/MicrosoftEdge/WebView2Feedback/issues
WebResourceRequested event can not get the url if this url open in an iframe.
try Network.Enable and Network.requestWillBeSent, can't get the url too.
uses CEF4delphi,Can it get all links in iFrame?
from webview4delphi.
Unless there's a WebView2 issue, the previous code should work. If not, please create an issue in the WebView2Feedback repository because this seems to be an upstream issue.
Please, use our forum for more questions.
from webview4delphi.
Related Issues (20)
- Console.log HOT 1
- Delphi can't find ToolsAPI.pas or designide.dcp HOT 1
- about DefaultScriptDialogsEnabled HOT 1
- Download files such as xls, PDF, CSV, etc HOT 3
- Update to Microsoft.Web.WebView2 1.0.1901.177 HOT 2
- When turning on 150% blooming on a 4K screen, the rendering page will pop out of the Tabsheet border HOT 1
- Unsupported WebView2Loader.dll version! HOT 1
- Acceleration Keys are not handled HOT 4
- UserAgent is not changed if i open link that has target='_blank' HOT 3
- App crash when initializing CEF and WebView2 browsers in the same form. HOT 2
- Tabbed Browser Demo: PixelsPerInch? HOT 2
- Nothing is visible, no rendering!? HOT 1
- The browser is not visible when vcl styles changed HOT 1
- Parameter OleVariant type in dynamic link library HOT 2
- Bug in Lazarus regarding the "ContextMenuRequested" event HOT 2
- Define for D2010 fix HOT 1
- When I run and terminated my application on debug mode, the application has leaked memory of TCoreWebView2Profile. (WebView4Delphi-1.0.2420.47) HOT 2
- Implement Internal_GetAvailableCoreWebView2BrowserVersionStringWithOptions HOT 1
- SimplaMonacoEditor HOT 8
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from webview4delphi.