2
votes

Using latest Phantomjs binaries v1.9.7 on Azure websites, it renders black boxes instead of character.

here is an example of simple phantomjs script on Azure:

var page = require("webpage").create();
page.content = "Hello 123";
page.render("index.png");
phantom.exit(0);

the png and pdf result is [] [] [] [] [] [] [] in black black boxes from phantomsJS on Azure Websites

And the jpg result is big black box

This prevent us from using phantomJS as a webjob and within websites

Note : phantomjs is working fine on VM,WebRole and WorkerRole

1
I think the question is related to my question:stackoverflow.com/questions/22900225/…Ammaroff
Where is index.png file located? If its located within your site wwwroot, try specifying the full path like d:\home\site\wwwroot\index.pngRanjith Ramachandra
the problem not in png location, the file is generated successfully but with black boxes as I mentioned. But I did what you said and the same problem is still thereAmmaroff

1 Answers

6
votes

PhantomJs uses GDI+ APIs from Windows for creating fonts and vectors in PNGs and PDFs which is, unfortunately, not supported currently on Azure Websites