Hi wonderful people.
I'm trying to do some DOM manipulation (groan) on the SYOS page (groan), and of course $(document).ready(); isn't going to work because the document is ready before the SYOS javascript writes to the DOM. Wondering if there exists any kind of event my script could latch on to that TNEW fires once the SYOS map has finished rendering?
Hi Nick,
The syosController does expose multiple events that you can add your own handlers. There are multiple components within the SYOS, so there are multiple events you can register.
If you wan to rearrange the legend, you could add a handler to fire after the legend is rendered like so:
syosController.legendRendered(function(e) {
<your code here>
});
You can see working examples in the page.SYOS.js file.
-Sam