kalyan.kkannan Posted January 2, 2015 Share Posted January 2, 2015 I want to render visualize js inside plain HTML, getting below error. Kindly help me to resolve the same.Uncaught SyntaxError: Invalid regular expression: /[À-ß][€-¿]|[à -ï][€-¿]{2}|[ð-÷][€-¿]{3}/: Range out of order in character classvisualize.html:11 Uncaught ReferenceError: visualize is not defined My Code <html><head><script src="http://127.0.0.1:8080/jasperserver-pro/client/visualize.js"></script> </head><body><div id="reportContainer">Loading..</div><script> visualize({ server: "http://127.0.0.1:8080/jasperserver-pro", auth: { name: "jasperadmin", password: "jasperadmin" }}, function (v) { v.report({ resource: "/public/chart", container: "#reportContainer", defaultJiveUi: { enabled: false }, error: function (err) { alert(err.message); } });}); </script> </body></html> Link to comment Share on other sites More sharing options...
hozawa Posted January 3, 2015 Share Posted January 3, 2015 Seems like visualize.js script file is not being loaded. First, you are using Commercial version of JasperReport Server aren't you? Visualize.js is not supported in community version.Try if you can access it by just entering the following from your web browser.http://127.0.0.1:8080/jasperserver-pro/client/visualize.jsTry deleting the following:server: "http://127.0.0.1:8080/jasperserver-pro", Link to comment Share on other sites More sharing options...
jleppa Posted January 5, 2015 Share Posted January 5, 2015 This SyntaxError is exactly same what I've seen as well. Link to comment Share on other sites More sharing options...
mcota_1 Posted January 5, 2015 Share Posted January 5, 2015 Please refer to the following:<html><head><script src="http://127.0.0.1:8080/jasperserver-pro/client/visualize.js?_opt=false"></script></head><body><div id="reportContainer">Loading..</div> <script>visualize({//server: "http://127.0.0.1:8080/jasperserver-pro",auth: {name: "jasperadmin",password: "jasperadmin",organization: "organization_1" } }, function (v) {v("#reportContainer").report({resource: "/public/Samples/Reports/01._Geographic_Results_by_Segment_Report", defaultJiveUi: { enabled: false },error: handleError }); function handleError(err){alert(err.message);} });</script></body></html>============================jsfiddle: http://jsfiddle.net/zwr2ohtz/ Link to comment Share on other sites More sharing options...
kalyan.kkannan Posted January 6, 2015 Author Share Posted January 6, 2015 On browser when hitting http://127.0.0.1:8080/jasperserver-pro/client/visualize.js, i am able to see the visualize.js getting downloaded. I simply used the above code but getting the below error. Uncaught TypeError: Cannot read property '2' of nullvisualize.js?_opt=false:9780 getLocationvisualize.js?_opt=false:10095 prepareTransportStackvisualize.js?_opt=false:10823 easyXDM.Rpcvisualize.js?_opt=false:12362 makeRpcvisualize.js?_opt=false:12515 (anonymous function)visualize.js?_opt=false:16059 (anonymous function)visualize.js?_opt=false:15902 jQuery.Callbacks.firevisualize.js?_opt=false:15948 jQuery.Callbacks.self.addvisualize.js?_opt=false:16058 (anonymous function)visualize.js?_opt=false:13187 jQuery.extend.eachvisualize.js?_opt=false:16055 (anonymous function)visualize.js?_opt=false:16115 jQuery.extend.Deferredvisualize.js?_opt=false:16054 jQuery.extend.Deferred.promise.thenvisualize.js?_opt=false:12514 Rootvisualize.js?_opt=false:12750 (anonymous function)visualize.js?_opt=false:1699 context.execCbvisualize.js?_opt=false:915 Module.checkvisualize.js?_opt=false:1192 Module.enablevisualize.js?_opt=false:823 Module.initvisualize.js?_opt=false:1465 (anonymous function) Link to comment Share on other sites More sharing options...
mcota_1 Posted January 6, 2015 Share Posted January 6, 2015 http://jsfiddle.net/zwr2ohtz/3/ What JasperReport Server version are you using? Thank you Link to comment Share on other sites More sharing options...
jleppa Posted January 7, 2015 Share Posted January 7, 2015 Looks like that parameter _opt=false is workaround for me. My version is Pro 6.0.1 (30day trial). 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