Re: Issuing a single command to multiple js scripts using a global


Forums > Javascript > Issuing a single command to multiple js scripts using a global
August 2, 2010 | 10:59 am

you have one global object and one global property to which you assign a callable in each client? then each assignment overwrites the previous one and only the last one gets called.

attached is an example of one way to handle this. I maintain a list of clients ("slaves") and route every message to those slaves who can handle it. The solution could be elaborated to support multiple master< ->>slaves bundles, but I never ran into a complex enough problem to want that :-)