1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 chrome.extension.onRequest.addListener(
6 function(url, sender, sendResponse) {
7 var req = new XMLHttpRequest();
8 req.open('GET', url, true);
10 req.onload = function() {
14 'text': req.responseText
17 req.onerror = function() {
21 'text': req.responseText
28 chrome.extension.sendRequest('injected');