[Project_owners] send data to a web page and process it without loading to browser.

Marco Pivetta ocramius at gmail.com
Thu Jul 24 03:55:18 PDT 2008


Default is false, of course ;)
Try making an XMLHttpRequest to
https://mysqladmin.helloweb.eu/index.php(should have a bad certificate
:S). Mozilla should stop it.
If mozBackgroundRequest is set to true then security checks should be
ignored ;)

2008/7/24 Jesper Staun Hansen <jesper at heroes-addon.dk>:

> I was considering how firefox 2 handles it. Default setting to false or
> true?
>
> Marco Pivetta wrote:
>
>> From the MDC:
>>
>>
>>      mozBackgroundRequest
>>
>> This property can be used to prevent authentication and bad certificate
>> dialogs from popping up for the request. Also the request will not be
>> canceled if the window it belongs to is closed. This property works for
>> chrome code only. New in Firefox 3 <
>> http://developer.mozilla.org/en/docs/Firefox_3_for_developers>
>>
>> There's nothing else about it :(
>>
>> 2008/7/24 Jesper Staun Hansen <jesper at heroes-addon.dk <mailto:
>> jesper at heroes-addon.dk>>:
>>
>>    Whats the story behind mozBackgroundRequest?
>>
>>    Marco Pivetta wrote:
>>
>>        Forgot to tell you that "req.mozBackgroundRequest=true;" works
>>        with FF3 only ;)
>>
>>        2008/7/24 Marco Pivetta <ocramius at gmail.com
>>        <mailto:ocramius at gmail.com> <mailto:ocramius at gmail.com
>>
>>        <mailto:ocramius at gmail.com>>>:
>>
>>
>>           I use tons of AJAX in my StOgame Extension ;)
>>
>>           As an example:
>>
>>                   var req=new XMLHttpRequest();
>>                   var postdata="l="+language+"&u="+universe; //MY DATA...
>>                   req.mozBackgroundRequest=true; //REQUEST DOESN'T
>>        GENERATE
>>           POPUPS AND/OR CERTIFICATE AGREEMENTS ETC...
>>                   req.onload=function()
>>                       {
>>           //CHECK READYSTATE
>>                           if(
>>                               (req.status==200)
>>                               &&(req.readyState==4)
>>                           )
>>                           {
>>           //CHECK IF PHP DIDNT CRASH XD
>>                               if(parseInt(req.responseText)==1)
>>                               {
>>                                   var
>>           expiration_timestamps=req.responseText.split(",");
>>                                   var playerranksstatusupdate=AccountDB
>>                                       .createStatement
>>                                       (
>>                                          //LET'S DO SOME COOL STUFF WITH
>>           SQLite ;)
>>                                       );
>>                                          //ETC...
>>                                 }
>>                           }
>>                           else
>>                           {
>>                               //ERROR: 404, PHP, SQL, ETC...
>>                           }
>>                       };
>>                   req.onprogress=function(e)
>>                       {
>>                           //alert("position: "+e.position+"\nototalSize:
>>           "+e.totalSize)
>>                       };
>>                   req.onreadystatechange=function()
>>                       {
>>                           //alert("readyState:
>>        "+req.readyState+"\nstatus:
>>           "+req.status);
>>                       };
>>                   req.onerror=function()
>>                       {
>>                           //alert("error!!!")
>>                       };
>>                   req.open('POST',
>>                 "
>> http://www.stogame.net/stogalaxy/test/rankupdatestatus.php",
>>        true);
>>
>> req.setRequestHeader('Content-Type','application/x-www-form-urlencoded');
>>           //USED FOR POST DATA
>>                   req.setRequestHeader("Content-length",
>>        postdata.length);
>>           //USED FOR POST DATA
>>                   req.setRequestHeader("Connection", "close");
>>                   req.send(postdata);
>>               }
>>
>>           2008/7/24 Silver Surfer <silver.surfer444 at gmail.com
>>        <mailto:silver.surfer444 at gmail.com>
>>           <mailto:silver.surfer444 at gmail.com
>>        <mailto:silver.surfer444 at gmail.com>>>:
>>
>>
>>
>>
>>                       On Thu, Jul 24, 2008 at 2:13 PM, Shivanand
>>        Sharma / Varun
>>               <varun21 at gmail.com <mailto:varun21 at gmail.com>
>>        <mailto:varun21 at gmail.com <mailto:varun21 at gmail.com>>> wrote:
>>
>>                   use hidden iframe?
>>
>>                   On Thu, Jul 24, 2008 at 1:50 PM, Silver Surfer
>>                   <silver.surfer444 at gmail.com
>>        <mailto:silver.surfer444 at gmail.com>
>>                   <mailto:silver.surfer444 at gmail.com
>>        <mailto:silver.surfer444 at gmail.com>>> wrote:
>>
>>                       Hi Friends,
>>                       I'm developing an new extension and I need to send
>>                       some data(user input) to a web page and do some
>>                       processing in there without loading that web
>>        page to
>>                       the browser. ( The functionality I need is
>>        similar to
>>                       the functionality of delicious firefox extension. )
>>                       But I still don't have an idea to call to
>>        script in a
>>                       web browser without loading it to the browser.
>>        I would
>>                       be very please if anyone of you can help me for
>>        this
>>                       problems.
>>                                       thanks & regards,
>>                       SS
>>
>>                       --                ~Silver Surfer~
>>                       Surfing through time & space
>>                       http://risingofsilversurfer.blogspot.com/
>>
>>                       _______________________________________________
>>                       Project_owners mailing list
>>                       Project_owners at mozdev.org
>>        <mailto:Project_owners at mozdev.org>
>>                       <mailto:Project_owners at mozdev.org
>>        <mailto:Project_owners at mozdev.org>>
>>
>>
>> https://www.mozdev.org/mailman/listinfo/project_owners
>>
>>
>>
>>
>>                   --            Cheers!
>>                   Shivanand Sharma
>>                   Editor: http://binaryturf.com <http://binaryturf.com/>
>>
>>                   Technology, Design, Monetization
>>
>>                   _______________________________________________
>>                   Project_owners mailing list
>>                   Project_owners at mozdev.org
>>        <mailto:Project_owners at mozdev.org>
>>        <mailto:Project_owners at mozdev.org
>>        <mailto:Project_owners at mozdev.org>>
>>
>>                   https://www.mozdev.org/mailman/listinfo/project_owners
>>
>>
>>               thanks Shivanand,
>>               it's a good idea. But I have another idea, If we can
>>        use AJAX
>>               in developing firefox extensions, then I think I can do
>>        what I
>>               want.
>>                       Can we use AJAX for developing extensions (
>>        Most probably I
>>               think we can, but need to confirm that idea).
>>               If so I think I can call to a PHP page with relevant
>>        user data
>>               and do the processing of that data.
>>               Am I correct friends?
>>
>>
>>               --        ~Silver Surfer~
>>               Surfing through time & space
>>               http://risingofsilversurfer.blogspot.com/
>>
>>               _______________________________________________
>>               Project_owners mailing list
>>               Project_owners at mozdev.org
>>        <mailto:Project_owners at mozdev.org>
>>        <mailto:Project_owners at mozdev.org
>>        <mailto:Project_owners at mozdev.org>>
>>
>>               https://www.mozdev.org/mailman/listinfo/project_owners
>>
>>
>>
>>
>>           --    Standard Ogame Project - StOgame
>>           http://www.stogame.net
>>           Making Ogame a better place...
>>
>>
>>
>>
>>        --        Standard Ogame Project - StOgame
>>        http://www.stogame.net
>>        Making Ogame a better place...
>>
>>  ------------------------------------------------------------------------
>>
>>
>>
>>        _______________________________________________
>>        Project_owners mailing list
>>        Project_owners at mozdev.org <mailto:Project_owners at mozdev.org>
>>        https://www.mozdev.org/mailman/listinfo/project_owners
>>
>>
>>    _______________________________________________
>>    Project_owners mailing list
>>    Project_owners at mozdev.org <mailto:Project_owners at mozdev.org>
>>    https://www.mozdev.org/mailman/listinfo/project_owners
>>
>>
>>
>>
>> --
>> Standard Ogame Project - StOgame
>> http://www.stogame.net
>> Making Ogame a better place...
>> ------------------------------------------------------------------------
>>
>> _______________________________________________
>> Project_owners mailing list
>> Project_owners at mozdev.org
>> https://www.mozdev.org/mailman/listinfo/project_owners
>>
>>
>
> _______________________________________________
> Project_owners mailing list
> Project_owners at mozdev.org
> https://www.mozdev.org/mailman/listinfo/project_owners
>



-- 
Standard Ogame Project - StOgame
http://www.stogame.net
Making Ogame a better place...
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.mozdev.org/pipermail/project_owners/attachments/20080724/4d383cc1/attachment-0001.html>


More information about the Project_owners mailing list