First of it depends of what you mean with anywhere? How much code are you allowed to publish to "anywhere".
Any how, the simplest way to publish anywhere is to just send "anywhere" a that implements the game. If you need different variables from each "anywhere" (for example for tracking) you can specify a .php file in the src attr that generates a javascript base on the parameters.
In the script you can use AJAX to talk to your sever and document.write to write at "anywhere" page.
One thing to keep in mind is that using a JS library could be hard since the "anywhere" page might no implement the specific JS library.
..fredrik