From: dhashi88 <dha...@ho...> - 2014-08-21 07:41:30
|
i was able to do in HtmlUnit 2.13 version by private static BrowserVersion firefox17WithUptoDateFlash = new BrowserVersion( BrowserVersion.FIREFOX_17.getApplicationName(), BrowserVersion.FIREFOX_17.getApplicationVersion(), BrowserVersion.FIREFOX_17.getUserAgent(), BrowserVersion.FIREFOX_17.getBrowserVersionNumeric(), new BrowserVersionFeatures[] { BrowserVersionFeatures.JS_FRAME_RESOLVE_URL_WITH_PARENT_WINDOW, BrowserVersionFeatures.STYLESHEET_HREF_EXPANDURL, BrowserVersionFeatures.STYLESHEET_HREF_STYLE_NULL }); static { PluginConfiguration plugin = new PluginConfiguration("Shockwave Flash", "Shockwave Flash 14.0 r0", "NPSWF32_14_0_0_145.dll"); plugin.getMimeTypes().add(new PluginConfiguration.MimeType("application/x-shockwave-flash", "Adobe Flash movie","swf")); //plugin.getMimeTypes().add(new PluginConfiguration.MimeType("application/futuresplash", "FutureSplash movie", "spl")); firefox17WithUptoDateFlash.getPlugins().add(plugin); } but same is not working for HtmlUnit 2.15 . what is the reason. How can i achieve this? |