-
Notifications
You must be signed in to change notification settings - Fork 28
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
balanced.js is broken #91
Comments
How were you using it? This file is in production for many marketplaces so I suspect this may have been misconfiguration on your end. Can you provide a reproducible example? |
I 've just copied balanced.js from github to my project, and it did not work. Where should 'global' be defined at? |
Global is defined by the browser. If you're copying it into your project it sounds like you're doing server side work. balanced.js is only for client side work and should never be hosted by you, only Balanced. Check out balanced-node if you're trying to do something on the server. I'm closing this issue since I suspect this is just balanced.js being misused. Reopen if I'm wrong :) |
'Included in my project' means I downloaded it from balanced-js github repo, placed on server side to be served to web browser clients. Specifically I develop using Chrome browser. I still cannot use balanced.js in Chrome the way it is. |
@vinkobuble you're still not giving me enough to reproduce and fix this error. I'm using Chrome 33 and if I go to http://jsfiddle.net/an5Cz/35/ it works as I'd expect it to. Does that page work for you? All this example is doing is including https://js.balancedpayments.com/1.1/balanced.js and then calling the tokenize method on it. Let me know if that works for you. If it doesn't then we can trouble shoot that, if it does then we need to find the difference between that example and your code. You can help by posting a gist of the rendered code so we can see what it looks like. How are you including balanced.js in your page. As I mentioned before I recommend you serve it from us, rather than serving it from your own source. |
Once I switched to this balanced.js it works. Thanks for help. |
Line 525: unknown object 'global'. I had to add line:
var global = {};
above to fix it.
The text was updated successfully, but these errors were encountered: