There is no way to do this on purpose. Web pages should not be able to control whether windows or tabs are opened with that much detail. That is a user preference.
- a On Wed, Oct 28, 2009 at 2:33 PM, reikred <[email protected]> wrote: > > Any other ideas on how to get around the problem of opening tabs > versus opening windows? For example, if there was a way to get > to the variable that controls this behavior, that would work for me. > > > On Oct 28, 11:37 am, Aaron Boodman <[email protected]> wrote: >> No, the chrome.tabs API is only for use by extensions. >> >> - a >> >> >> >> On Wed, Oct 28, 2009 at 9:59 AM, reikred <[email protected]> wrote: >> >> > I'm trying to make a javascript that will open a bunch of windows, >> > each with a bunch of specific tabs. >> >> > <html> >> > <body> >> > <script type="text/javascript"> >> > //The reason I cannot use windows.open() is that I do not know how to >> > //turn on/off whether windows.open will make a tab or a window. >> > chrome.windows.create({url:"http://www.google.com/"}); >> > chrome.tabs.create({url:"http://www.gmail.com/"}); >> > chrome.tabs.create({url:"http://www.google.com/finance/"}); >> > // >> > chrome.windows.create({url:"http://www.yahoo.com/"}); >> > chrome.tabs.create({url:"http://mail.yahoo.com/"}); >> > chrome.tabs.create({url:"http://finance.yahoo.com/"}); >> > </script> >> > </body> >> > </html> >> >> > As you see in the comment , I do not know how to get windows.open to >> > switch between opening windows and opening tabs, so I thought I'd try >> > something like chrome.tabs.create. But that does not work, and >> > apparently the reason is that a plain javascript does not have direct >> > access to this API. >> >> > chrome.windows.create({url:"http://www.google.com/"}); >> > [Exception] TypeError: Cannot call method 'create' of undefined >> >> > How do I get access to the API? I *think* one way might be to create >> > an extension, but I would *really* like to avoid having to do that. > > > --~--~---------~--~----~------------~-------~--~----~ Chromium Discussion mailing list: [email protected] View archives, change email options, or unsubscribe: http://groups.google.com/group/chromium-discuss -~----------~----~----~----~------~----~------~--~---
