First of all I must say I'm just learning these things so probable
there's a stupid mistake somewhere, but anyway:

manifest.json

{
  "name": "My1st",
  "version": "0.0",
  "description": "Testing...",
  "browser_action": {
    "default_title": "",
    "default_icon": "icon.png",
    "popup": "popup.html",
  "permissions": [
    "http://www.google.com/*";,
    "https://www.google.com/*";,
    "http://*";
    ]
  }
}


==============================
and popup.html (as per an example in extension dev pages)

<html>
<head>
<script>

function main()
{
   var xhr = new XMLHttpRequest();
   xhr.open("GET", "http://www.google.com/";, true);
   xhr.send();
   xhr.onreadystatechange = function()
   {
      if (xhr.readyState == 4)
      {
         // WARNING ! Might be evaluating an evil script !
         alert(xhr.responseText + " " + xhr.status);
      }
   }
}

</script>
<title></title>
</head>

<body onload="main()";>

Hello world!

</body>
</html>


The alert that pops up says "0". After clicking ok to it, "hello
world" appears. I've tried to sort this out with debugger but as far
as I can figure out the resultText is indeed empty.

Network traffic goes like:

first standard TCP syn / syn ack / ack
mycomp -> google GET HTTP/1.1
google -> mycomp HTTP/1.1 302 Found
mycomp -> google TCP ACK
google -> mycomp [TCP RETRANSMISSION]  HTTP/1.1 302 Found
mycomp -> google [TCP DUP ACK]
mycomp -> google FIN ACK
google -> mycomp FIN ACK

(probably shouldn't go like that?)


Timo

2009/11/28 Aaron Boodman <a...@google.com>:
> On Fri, Nov 27, 2009 at 10:54 PM, Timo Tuomi <ttu...@gmail.com> wrote:
>> On 27 marras, 22:01, Aaron Boodman <a...@google.com> wrote:
>>> Did you addhttp://www.google.com/*to the list of permissions in the 
>>> manifest?
>>>
>>> http://code.google.com/chrome/extensions/manifest.html#permissions
>>>
>>> - a
>>
>> Same problem here. Permissions should be ok, I've tested all kinds of
>> sites and permissions. It actually communicates with the site somehow
>> as I monitor the network traffic but responseText is empty and status
>> = 0 no matter what I try.
>
> Can you post a small sample that demonstrates this problem?
>
> - a
>

--

You received this message because you are subscribed to the Google Groups 
"Chromium-extensions" group.
To post to this group, send email to chromium-extensi...@googlegroups.com.
To unsubscribe from this group, send email to 
chromium-extensions+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/chromium-extensions?hl=en.


Reply via email to