can i store a value returned by apex method in a javascript variable?
Is it possible to store a value returned by a controller method into a javascript variable?
i need to pass a date and sales qty from salesforce into flot library javascript to build a graph. So what i am doing is formatting a string in apex with the da开发者_如何转开发te and salesqty as required by flot library and returning it in the method.
Can i say in my javascript
var d={!getformatteddata};
Thanks
Prady
You can do this, just omit the leading 'get':
var d='{!formatteddata}';
精彩评论