Uncaught TypeError: Object # <a document> does not have a 'write' method?

When I try to enable the google visualization of api on a page in the Google engine, getting this error in the Chrome developer tool console: Uncaught TypeError: Object # does not have a 'write' method

In FF 3.5, the error "n.write is not a function". A little bit about Noob here and don't know how to fix this problem. Any ideas?

The code can be found here: Google visualization api on the application engine does not work ... (python)

+4
source share
2 answers

If anyone else has this problem, I messed up the page headers generated by the rendering with the same function that I created for XML output.

Including it killed him: handler.response.headers ["Content-Type"] = "text / xml"

+2
source

If you use JSF2 and XHTML limits, you need to use:

<f:view contentType="text/html"> <!-- page with charts here --> </f:view> 
0
source

Source: https://habr.com/ru/post/1302547/


All Articles