aksharaloni Posted November 1, 2015 Share Posted November 1, 2015 Hi,Most of the examples I saw under visualize.js are using localhost. I do not have jasperserver installed on local, so I am trying to connect to remote server to create sample html using visualize.js. But I am not able to see the report on html and getting below error.TypeError: t is nullhttp://myremoteserver:8080/reportservice/client/visualize.jsLine 64Here is simple html:<!DOCTYPE html><html><head><meta charset="utf-8"><title>Test Visualize</title> </head><body><h2>Simple Visualize.js</h2><div id="container"></div><script type="text/javascript" src="http://myremoteserver:8080/reportservice/client/visualize.js"></script><script type="text/javascript">visualize( { auth:{ name:"admin", password:"admin",organization:"test" } },function (v){//render report from provided resource v("#container").report({ resource: "/organizations/test/temp/MyReport", error: handleError }); //show error function handleError(err) { alert(err.message); }});</script></body></html> I am wondering if remote server is supported or not. If not how can I create simple html and test report with visualize.js ? Thanks Link to comment Share on other sites More sharing options...
hozawa Posted November 1, 2015 Share Posted November 1, 2015 Remote servers are supported because I'm using it in one of my site.I just tested it on a local server and replaced the server ip address afterward.There may be a firewall preventing access.1. Check if visualize.js file on the remote server can be opened from the web browser.2. Check if the report can be accessed using REST v2 API. Link to comment Share on other sites More sharing options...
aksharaloni Posted November 2, 2015 Author Share Posted November 2, 2015 Thanks for your inputs. To answer your question1. Yes, I can access visualize.js from the browser2. Not sure how to check if report is access through rest api. Can you help me with this ?Thanks. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now