Windows Phone - No HTML/CSS/JS Override


How do we go about overriding the original HTML/CSS/JS in the web browser control?
Closed Jan 7, 2015 at 4:52 PM by boyofgreen


martinkearn_msft wrote Mar 13, 2014 at 8:07 AM

You can override the CSS using injected-styles.css, but you cannot override the HTML or JS as far as I know. However, I have a feeling JS injection may be coming soon which would allow you to manipulate the HTML DOM too.

dthompson_cc wrote Mar 14, 2014 at 7:17 PM

Thanks for the follow-up, however I was specifically referring to the WINDOWS PHONE code.

the missing piece of code to implement the GetInvokeString() was:
    private void Browser_LoadCompleted(object sender, NavigationEventArgs e)
            string invokeString = _webConfig.Styles.GetInvokeString();
            Browser.InvokeScript("eval", new string[] { invokeString });