laurentj / slimerjs

A scriptable browser like PhantomJS, based on Firefox
http://slimerjs.org
Other
3k stars 258 forks source link

Flash content doesn't load #663

Closed iKethavel closed 6 years ago

iKethavel commented 6 years ago

Versions

Steps to reproduce the issue

Paste code and run

Actual results:

Doesn't load flash content

Expected results:

Successfully loaded flash content

const pageFactory = require('webpage');   // factory for webpage objects
const page = pageFactory.create();    // main page which loads data pages at angel.co/jobs
const FLASH_TEST = 'https://www.adobe.com/swf/software/flash/about/flashAbout_info_small.swf';
const CHIBI_URL = 'http://www.dolldivine.com/chibi-maker.php';

page.viewportSize = {width: 1366, height: 768};
page.open(CHIBI_URL, function () {
    console.log(`opened`);

    setTimeout(function () {

        page.evaluate(function () {
            window.scrollBy(0, 200);
            document.querySelector('embed').click();
        })

        page.render('screenshot.png')

    }, 10000)

});
laurentj commented 6 years ago

Flash content is probably loaded, but it doesn't appear in screenshots. See the FAQ: https://docs.slimerjs.org/current/faq.html#i-don-t-see-flash-content-when-i-take-a-screenshot-with-render

iKethavel commented 6 years ago

But in browser preview is also doesn`t show?

So, slimerjs can't crew screenshot data from flash content?(

laurentj commented 6 years ago

If the flash content is not shown in the window opened by SlimerJS, probably it's because:

Anyway, even if Flash content is loaded correctly, it won't appear in a screenshot because of a bug in Firefox (see FAQ).

iKethavel commented 6 years ago

Anyway, even if Flash content is loaded correctly, it won't appear in a screenshot because of a bug in Firefox (see FAQ).

In that flash app has the opportunity to save image, can i do that with slimerjs? ( http://www.dolldivine.com/chibi-maker.php )

laurentj commented 6 years ago

Probably. Never tested.