Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Post data on new tab/new window/current window ?

54 views
Skip to first unread message

Yep

unread,
Jan 24, 2007, 8:54:55 AM1/24/07
to
Hi there,

I don't find answers to my question. I'm currently developping an
extension for firefox and I would like to post data when I load an URL
in :
- the current window
- a new tab
- in a new window

To post data in a new tab, I know that's possible :
http://developer.mozilla.org/en/docs/XUL:Method:addTab
But I don't find a way to post data in the current window or in a new
window.

Can anyone help me please ?

Mark Finkle

unread,
Jan 24, 2007, 11:33:18 PM1/24/07
to
When your in the current window and you want to POST data somewhere, the
easiest way could be XMLHttpRequest:

http://developer.mozilla.org/en/docs/XMLHttpRequest

Mark Finkle

Yep

unread,
Jan 25, 2007, 4:54:16 AM1/25/07
to
hmmm ... if I use XMLHttpRequest, the result of request will be not
display on the screen (in the current window). What I need to do is
load a web page in the current window with posted data.

eric...@yahoo.com

unread,
Jan 25, 2007, 2:24:22 PM1/25/07
to dev-ext...@lists.mozilla.org
You can load content into existing browsers with nsIURILoader::openURI
http://www.xulplanet.com/references/xpcomref/ifaces/nsIURILoader.html

_______________________________________________
dev-extensions mailing list
dev-ext...@lists.mozilla.org
https://lists.mozilla.org/listinfo/dev-extensions

Neil

unread,
Jan 25, 2007, 2:51:21 PM1/25/07
to
Yep wrote:

>To post data in a new tab, I know that's possible :
>http://developer.mozilla.org/en/docs/XUL:Method:addTab
>But I don't find a way to post data in the current window or in a new window.
>
>

Call loadURI(aURI, aReferrer, aPostData) to post data in the current window.
Call window.openDialog('chrome://browser/content', '_blank', 'all,
dialog=no', aURI, aReferrer, aPostData) to post data in a new window.

--
Warning: May contain traces of nuts.

Yep

unread,
Jan 26, 2007, 12:10:13 PM1/26/07
to
Hey, hey ! Thanks a lot, I will make some tests with this :)

On 25 jan, 20:51, Neil <n...@parkwaycc.co.uk> wrote:
> Yep wrote:
> >To post data in a new tab, I know that's possible :
> >http://developer.mozilla.org/en/docs/XUL:Method:addTab

> >But I don't find a way to post data in the current window or in a new window.Call loadURI(aURI, aReferrer, aPostData) to post data in the current window.

0 new messages