OLD | NEW |
1 <h1>Message Passing</h1> | 1 <h1>Message Passing</h1> |
2 | 2 |
3 | 3 |
4 <p> | 4 <p> |
5 Since content scripts run in the context of a web page and not the extension, | 5 Since content scripts run in the context of a web page and not the extension, |
6 they often need some way of communicating with the rest of the extension. For | 6 they often need some way of communicating with the rest of the extension. For |
7 example, an RSS reader extension might use content scripts to detect the | 7 example, an RSS reader extension might use content scripts to detect the |
8 presence of an RSS feed on a page, then notify the background page in order to | 8 presence of an RSS feed on a page, then notify the background page in order to |
9 display a page action icon for that page. | 9 display a page action icon for that page. |
10 | 10 |
(...skipping 440 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
451 <a href="http://src.chromium.org/viewvc/chrome/trunk/src/chrome/common/extension
s/docs/examples/api/messaging/">examples/api/messaging</a> | 451 <a href="http://src.chromium.org/viewvc/chrome/trunk/src/chrome/common/extension
s/docs/examples/api/messaging/">examples/api/messaging</a> |
452 directory. | 452 directory. |
453 <a href="http://src.chromium.org/viewvc/chrome/trunk/src/chrome/common/extension
s/docs/examples/api/nativeMessaging/">examples/api/nativeMessaging</a> | 453 <a href="http://src.chromium.org/viewvc/chrome/trunk/src/chrome/common/extension
s/docs/examples/api/nativeMessaging/">examples/api/nativeMessaging</a> |
454 contains an example application that uses native messaging. | 454 contains an example application that uses native messaging. |
455 Also see the | 455 Also see the |
456 <a href="http://src.chromium.org/viewvc/chrome/trunk/src/chrome/common/extension
s/docs/examples/howto/contentscript_xhr">contentscript_xhr</a> example, | 456 <a href="http://src.chromium.org/viewvc/chrome/trunk/src/chrome/common/extension
s/docs/examples/howto/contentscript_xhr">contentscript_xhr</a> example, |
457 in which a content script and its parent extension exchange messages, | 457 in which a content script and its parent extension exchange messages, |
458 so that the parent extension can perform | 458 so that the parent extension can perform |
459 cross-site requests on behalf of the content script. | 459 cross-site requests on behalf of the content script. |
460 For more examples and for help in viewing the source code, see | 460 For more examples and for help in viewing the source code, see |
461 <a href="samples.html">Samples</a>. | 461 <a href="samples">Samples</a>. |
462 </p> | 462 </p> |
OLD | NEW |