Patent ID: 8065659

Claim:
A method for extending a scripting language native to a web browser to facilitate executing scripts within the web browser, the method comprising: receiving a first command from a root script to initialize a first worker script within a web browser, wherein the first command includes a first Uniform Resource Locator (URL) that specifies the location of the first worker script; and in response to the first command: creating a first operating-system thread, wherein creating the first operating-system thread involves creating a first identifier for the first operating-system thread, and returning the first identifier to the root script, and the first operating-system thread is associated with a first message queue; starting a first worker script-engine using the first operating-system thread, receiving a first message at the first message queue to execute the first worker script, and in response to the first message, executing the first worker script within the first worker script-engine, wherein executing the first worker script involves retrieving the first worker script from a location specified by the first URL.