Gelmiş geçmiş en büyük porno sitemiz olan 2pe de her zaman en kaliteli pornoları sunmayı hedefledik. Diğer video sitemiz olan vuam da ise hd porno ağırlıklı çalışmalara başladık.

  1. #171
    Ext JS Premium Member
    Join Date
    Jul 2007
    Posts
    218
    Vote Rating
    0
    ZooKeeper is on a distinguished road

      0  

    Default


    Doug! Thanks a lot for your terrific work in keeping all you projects going and so constantly supported.

    I've got maybe not exactly basex question here, but what the heck.

    I want to implement such a behavior that when I make Ext.Ajax.request it'll always have isJson option turned on, but for Store requests for it to be off.

    I want this for:
    1) Not writing isJson with every single request i make (which is a lot)
    2) Not make a useless and really expensive Ext.decode on the data for stores.

    If I override Ext.lib.Ajax and set isJson: true that makes it decode in both cases.
    So how do i specifically turn it on only for Ajax.requests?

    Thanks

  2. #172
    Sencha - Community Support Team hendricd's Avatar
    Join Date
    Aug 2007
    Location
    Long Island, NY USA
    Posts
    5,962
    Vote Rating
    10
    hendricd will become famous soon enough hendricd will become famous soon enough

      0  

    Default


    Quote Originally Posted by ZooKeeper View Post
    Doug! Thanks a lot for your terrific work in keeping all you projects going and so constantly supported.

    I've got maybe not exactly basex question here, but what the heck.

    I want to implement such a behavior that when I make Ext.Ajax.request it'll always have isJson option turned on, but for Store requests for it to be off.

    I want this for:
    1) Not writing isJson with every single request i make (which is a lot)
    2) Not make a useless and really expensive Ext.decode on the data for stores.

    If I override Ext.lib.Ajax and set isJson: true that makes it decode in both cases.
    So how do i specifically turn it on only for Ajax.requests?

    Thanks
    @ZooKeeper --
    You have a few options.

    My personal preference for store-load-efficiency (and error recovery):

    PHP Code:
    //Ext 2.2 shown here.
    Ext.overrideExt.data.JsonReader, {
       
    read : function(response){
            var 
    response.responseJSON || Ext.decoderesponse.responseText);
            if(!
    o) {
                throw {
    message"JsonReader.read: Json object not found"};
            }
            return 
    this.readRecords(o);
        }
    }); 
    Might as well take advantage of it, right?

    So, your JSON responses SHOULD return a suitable Content-Type of "application(/text)/json" or set {isJSON:true} in your load statement. If neither happens, there will be no responseJSON value and regular eval would take place by the reader.

    For global flexibility, you have a couple of options:

    PHP Code:
    //without a decoder defined, there is no eval, thus no responseJSON !
    var Ext.lib.Ajax;
    A.setJSON = function(bool){
       
    A.decodeJSON bool Ext.decode false;
    }; 
    or, get silly with:
    PHP Code:

    IwantJSON 
    true//global switch

     
    Ext.lib.Ajax.on'request' , function(methoduricbdataoptions){
        
    options || (options = {}); //assert any options
        
    options.isJSON IwantJSON;
    }); 
    Make sure your using the latest 3.1 from SVN.

    Use some or all. Tweak it!
    "be dom-ready..."
    Doug Hendricks

    Maintaining ux: ManagedIFrame, MIF2 (FAQ, Wiki), ux.Media/Flash, AudioEvents, ux.Chart[Fusion,OFC,amChart], ext-basex.js/$JIT, Documentation Site.


    Got Sencha licensing questions? Find out more here.


  3. #173
    Ext JS Premium Member
    Join Date
    Jul 2007
    Posts
    218
    Vote Rating
    0
    ZooKeeper is on a distinguished road

      0  

    Default


    Thanks for the a reply!

    I've got the same content type for all my JSON coming out so this leaves me to setting isJSON manually for each request i make...

    PHP Code:
     Ext.lib.Ajax.on'request' , function(methoduricbdataoptions){
        
    options || (options = {}); //assert any options
        
    options.isJSON IwantJSON;
    }); 
    again sets isJson for all requests..

    Is there a way to make isJson=true globally for all Ext.AJAX.requests and leave it false for all store loads?

  4. #174
    Sencha - Community Support Team hendricd's Avatar
    Join Date
    Aug 2007
    Location
    Long Island, NY USA
    Posts
    5,962
    Vote Rating
    10
    hendricd will become famous soon enough hendricd will become famous soon enough

      0  

    Default


    @ZooKeeper -- You may still be confused. basex populates responseJSON automatically when:

    (response.content-type == '(application|text)/json' or options.isJSON == true ) and
    typeof Ext.lib.Ajax.decodeJSON == function [eg. Ext.decode]

    Quote Originally Posted by ZooKeeper View Post
    I've got the same content type for all my JSON coming out so this leaves me to setting isJSON manually for each request i make...
    What content-type are you sending back for JSON responses? One of the above? If not, your server isn't following the RFC for JSON. If it is, your stores are just fine with the JSON.Reader override (any actual JSON response would only get evaled once for data.Stores).

    Quote Originally Posted by ZooKeeper View Post
    Is there a way to make isJson=true globally for all Ext.AJAX.requests and leave it false for all store loads?
    By somehow setting isJSON true for all requests, an attempt will be made thoughout the framework to eval all responses (XML, HTML as well). Any eval failure there would force an exception and your Ajax request would fail even though it got a valid (HTML/XML) responseText. Setting isJSON globally would not be a good idea (unless your App ran on pure JSON alone).
    "be dom-ready..."
    Doug Hendricks

    Maintaining ux: ManagedIFrame, MIF2 (FAQ, Wiki), ux.Media/Flash, AudioEvents, ux.Chart[Fusion,OFC,amChart], ext-basex.js/$JIT, Documentation Site.


    Got Sencha licensing questions? Find out more here.


  5. #175
    Sencha - Community Support Team hendricd's Avatar
    Join Date
    Aug 2007
    Location
    Long Island, NY USA
    Posts
    5,962
    Vote Rating
    10
    hendricd will become famous soon enough hendricd will become famous soon enough

      0  

    Default $JIT Lives!

    $JIT Lives!


    Well after months of all talk and "no show", the wait is over.

    With all the required enhancements to ext-basex now completed (v 3.1 required), $JIT arrives sporting a cool flickr photo-browser demo located here (careful, it's addictive to watch ). But, the important thing to note is the initial load time.

    The demonstration is based upon standard Ext 2.0.2 'packages' (with a few package tweaks) and demonstrates how to load portions of Ext on an "as-needed" basis (rather than ext-all.js).

    So, what is $JIT?

    Well, "Just in Time" man! And, no, it's not a compiler.

    It's a means to deliver external resources to your browser (Text, Markup, JSON, code, CSS, XML) with dependency management options as well.

    $JIT sits on top of ext-basex (and the included Ext.ux.ModuleManager) and requires no server-side support, providing a new way of structuring large dynamic RIAs.

    The basic philosophy goes like this:

    1) Use the standard Ext /package builds (already provided in ext.jsb) or create your own required configuration for deployment (and not just for Ext either).

    2) Then, tell $JIT what your packages look like. Here is an example:
    PHP Code:
     $JIT.depends"mygrid" ]  =  {path"assets/",   depends: [ '@layouts''@panelDD''@fullgrid' ] } 
    The following statement would load 'assets/mygrid.js' after the layout, panelDD, and fullgrid packages were (or already) loaded (in the declared order) and optionally execute a callback function when completed:
    PHP Code:
    $JIT('mygrid'buildUI ); 
    And, any of those packages may also contain other $JIT commands, loading additional resources they may require as well.

    3)Then, load just the core Ext code (ext-base, ext-core, ext-basex, jit, ext-all.css) into your pages' <head> section as usual.

    4) Then, $JIT takes over. Here's a simplified example:

    PHP Code:
      $JIT( {method:'GET'},  //Ajax for standard packages
              
    'panel'
              
    'dragdrop'
              
    'grid'
              {
    method:'DOM'modulePath:'assets/'},   //switch to <script> tag mode for debugging.
              
    'custom.css'
              'myApp'
    ,
              function(
    allLoaded){  //not executed until all dependencies are delivered
                  
    if(allLoaded){
                      
                       
    buildUI();
                  }
              }
         ); 
    And, you don't have code things proceduraly. $JIT is fully asynchronous (naturally, synchronous requests are supported too), so you can wait for a previously requested resource (elsewhere in your scripts) and act on them:
    PHP Code:
         $JIT.onAvailable'custom.css', function(ok){
           if(
    ok)   
             
    $JIT.applyStyle('custom.css');  //apply the stylesheet as soon as it arrives (removeStyle to clear it)
          
    }, scope5000);   //5 second timeout 
    And, you can wait for a specific class to arrive:
    PHP Code:
     var showPurchases = function(toTabPanel){
        
    $JIT('purchasesGrid');
        
    $JIT.onClassAvailable'App.Customer.Purchases.Grid', function(ok){
           if(
    ok) {  
                var 
    this.add(new App.Customer.Purchases.Grid( {....}));
                
    this.rendered && this.doLayout();
                
    this.setActiveTab(G);
           }
          }, 
    toTabPanel5000);   //5 second timeout

      
    }; 
    And, talk about "lazy-loading"! $JIT adds this feature to the Ext.ComponentMgr:
    PHP Code:
    tabs.add({
       
    xtype'panel',
       
    layout 'fit',
       
    JIT  :  ['gridFixes''gridfilters''ux/snapons'],
       
    items:[ .... ]
     }); 
    Since $JIT uses ext-basex, you've also got Queuing and proxied (<script> tag) requests built in. See the demos' flikr.js source file for an example of that loading a store/dataview.

    WAY too much to document here, but you should get the idea. Documentation and more samples are coming to the demo site (all based on $JIT of course)

    The latest 4.0 build can be found in /trunk.
    Enjoy.
    "be dom-ready..."
    Doug Hendricks

    Maintaining ux: ManagedIFrame, MIF2 (FAQ, Wiki), ux.Media/Flash, AudioEvents, ux.Chart[Fusion,OFC,amChart], ext-basex.js/$JIT, Documentation Site.


    Got Sencha licensing questions? Find out more here.


  6. #176
    Ext User
    Join Date
    Jul 2007
    Location
    Taiwan
    Posts
    24
    Vote Rating
    0
    kevinwu8 is on a distinguished road

      0  

    Default


    Hi.Doug..

    I have a login system..
    Now i wish user submit this login form can use HTTP authentication via ext-basex..
    Here is my submitForm function code..But it not work...
    PHP Code:
    var submitForm = function() {
         
    Ext.lib.Ajax.request({                
                    
    async:false,
                    
    url:submitUrl,
                    
    method 'POST',
                    
    userId:'userID',
                    
    password:'userPWD'                
                    
    });

    Would you please help me??...

    very thanks..

    Kevin..

  7. #177
    Sencha - Community Support Team hendricd's Avatar
    Join Date
    Aug 2007
    Location
    Long Island, NY USA
    Posts
    5,962
    Vote Rating
    10
    hendricd will become famous soon enough hendricd will become famous soon enough

      0  

    Default


    @kevinwu8 -- Review this and some of the other references included there, and make sure that 'Basic Auth' is something your really want (ie. is your site going to be public-facing without SSL?)

    The userID/password submitted in HTTP headers are easily base64-decoded for viewing by the public.

    If your talking about an intranet or SSL, try:

    Code:
    var submitLogin = function(userId, password) {
    
         //Auth values passed in the open (base64 encoded)
         Ext.Ajax.defaultHeaders.Authorization = "Basic "+ yourEncodebase64Fn(userId + ':' + password);
    
         OR: 
    
         Ext.Ajax.request({                
                    async:false,
                    url:submitUrl,
                    method : 'POST',
                    userId:userId,
                    password:password                
                    });
    
        OR:
    
         Ext.lib.Ajax.request('POST', submitURL, null, data, 
                   {                
                    async:false,
                    userId:userId,
                    password:password                
                    });
    }
    If you choose the generic route, you will need to provide the necessary base64 encoding function (yourEncodebase64Fn) for the header (here is one).
    "be dom-ready..."
    Doug Hendricks

    Maintaining ux: ManagedIFrame, MIF2 (FAQ, Wiki), ux.Media/Flash, AudioEvents, ux.Chart[Fusion,OFC,amChart], ext-basex.js/$JIT, Documentation Site.


    Got Sencha licensing questions? Find out more here.


  8. #178
    Ext JS Premium Member
    Join Date
    May 2008
    Posts
    528
    Vote Rating
    0
    Eric24 is on a distinguished road

      0  

    Default Base-X Proxied Example?

    Base-X Proxied Example?


    Doug,

    Do you have a simple example of using a proxied cross-domain request with base-x?

    Thanks!
    Eric

  9. #179
    Sencha - Community Support Team hendricd's Avatar
    Join Date
    Aug 2007
    Location
    Long Island, NY USA
    Posts
    5,962
    Vote Rating
    10
    hendricd will become famous soon enough hendricd will become famous soon enough

      0  

    Default Proxied JSONP Request Sample

    Proxied JSONP Request Sample


    Quote Originally Posted by Eric24 View Post
    Doug,

    Do you have a simple example of using a proxied cross-domain request with base-x?

    Thanks!
    Eric
    This is the relevant proxied JSONP request for flickr.com browser ( $JIT) demo:
    PHP Code:
                          //Make a proxied JSONP request to access the flickr API in JSON mode
                               
    Ext.Ajax.request({
                                        
    url       'http://www.flickr.com/services/rest'
                                       
    ,isJSON    true  //they'll be no responseHeaders so, set the hint

                                       
                                       
    ,proxied   :{
                                           
    debug:true,  //Preserves the <script> tag for examination
                                           
    callbackParam'jsoncallback'
                                           
    //callbackName : define callback functions of your own 
                                           
    }
                                       ,
    params:{
                                               
    page  startPage || 1,
                                               
    per_page 50,
                                               
    method :'flickr.photos.getRecent',
                                               
    extras 'tags,views,date_taken',
                                               
    format :'json',
                                               
    api_key this.apiKey
                                             
    }

                                        ,
    callback : function(options,success,response){

                                            var 
    troublephotos response.responseJSON;
                                                                        
    //.responseXML,
                                                                       // .responseText(could be anything presented via JSONP, [careful here])

                                            
    if(/*transport*/ success && photos){ 

                                                if(
    photos.stat == 'ok'){
                                                    
    this.activePage parseInt(photos.page ,10) || 1;
                                                    
    this.store.loadData(photos);
                                                } else {
                                                    
    trouble String.format('flikr.com reports a problem:<br />Status: {0}<br />Reason:{1}<br />{2}',photos.stat,photos.code,photos.message );
                                                }
                                            } else {
                                                
    trouble String.format('The Remote request to Flikr.com failed:<br />Reason:{0}<br />{1}-{2}<br />{3}'
                                                   
    ,response.status
                                                   
    ,response.statusText
                                                   
    ,response.fullStatus.error?response.fullStatus.error.description null
                                                   
    ,response.fullStatus.text );
                                            }
                                            if(
    trouble){
                                                
    this.thumbView.getEl().update(trouble);
                                            }
                                           
                                            
    this.thumbView.hideMask();

                                        }
                                        ,
    scopethis
                                     
    }); 
    "be dom-ready..."
    Doug Hendricks

    Maintaining ux: ManagedIFrame, MIF2 (FAQ, Wiki), ux.Media/Flash, AudioEvents, ux.Chart[Fusion,OFC,amChart], ext-basex.js/$JIT, Documentation Site.


    Got Sencha licensing questions? Find out more here.


  10. #180
    Ext JS Premium Member
    Join Date
    May 2008
    Posts
    528
    Vote Rating
    0
    Eric24 is on a distinguished road

      0  

    Default


    Perfect--exactly what I was looking for!

    On a related note, do you happen to know how to get Firebug to show proxied requests? Under Console or Net, it shows all requests to the origin domain, but even if I enable FB globally, it still doesn't seem to show the proxied transactions. Am I missing something or is it just not possible for FB to show these?

Thread Participants: 82

  1. galdaka (1 Post)
  2. Digital God (3 Posts)
  3. prophet (1 Post)
  4. alayasf (2 Posts)
  5. tof (1 Post)
  6. stever (3 Posts)
  7. mystix (4 Posts)
  8. fangzhouxing (6 Posts)
  9. ludoo (1 Post)
  10. KRavEN (4 Posts)
  11. DigitalSkyline (3 Posts)
  12. daemach (1 Post)
  13. violinista (1 Post)
  14. mlarese (1 Post)
  15. walker_cn (4 Posts)
  16. stevebla (4 Posts)
  17. Chris in Cambridge (1 Post)
  18. mjlecomte (2 Posts)
  19. ZooKeeper (10 Posts)
  20. brookd (1 Post)
  21. fermo111 (6 Posts)
  22. kevinwu8 (1 Post)
  23. Spirit (3 Posts)
  24. jerrybrown5 (4 Posts)
  25. lvanderree (8 Posts)
  26. Makor (4 Posts)
  27. yanick (1 Post)
  28. wm003 (10 Posts)
  29. radio1 (3 Posts)
  30. jphillips (2 Posts)
  31. markpele (2 Posts)
  32. Romantik (1 Post)
  33. Sander_S (4 Posts)
  34. maximumcoder (2 Posts)
  35. NotChris (6 Posts)
  36. ritchrs (2 Posts)
  37. sksoft (2 Posts)
  38. jvanantwerp (2 Posts)
  39. jfa (2 Posts)
  40. BlueCamel (1 Post)
  41. ClemsonJeeper (3 Posts)
  42. sp797 (1 Post)
  43. mahesh122 (2 Posts)
  44. zombeerose (12 Posts)
  45. jlowe (2 Posts)
  46. bt_bruno (2 Posts)
  47. pompom (4 Posts)
  48. Eric24 (18 Posts)
  49. baumschule (3 Posts)
  50. coderobo (3 Posts)
  51. krause (1 Post)
  52. mubenchi (1 Post)
  53. mrkadakia (3 Posts)
  54. tomim (4 Posts)
  55. canxss (2 Posts)
  56. tasman (3 Posts)
  57. mrsunshine (4 Posts)
  58. Trinad (2 Posts)
  59. jasonb885 (2 Posts)
  60. wki01 (5 Posts)
  61. mschwartz (2 Posts)
  62. sarathy (2 Posts)
  63. jdurante (1 Post)
  64. TomChiverton (1 Post)
  65. sumit.madan (2 Posts)
  66. Riemi (4 Posts)
  67. Henrik Rutzou (3 Posts)
  68. hairinwind (1 Post)
  69. gzlizp (1 Post)
  70. yuanqixun (2 Posts)
  71. larryaubstore (2 Posts)
  72. wupeng (2 Posts)
  73. blueram (1 Post)
  74. ronivcp (1 Post)
  75. t00bs (2 Posts)
  76. hyponym (4 Posts)
  77. mg2468 (3 Posts)
  78. scaddenp (1 Post)
  79. faith wins (3 Posts)
  80. aratcliffe (8 Posts)
  81. jhashe (3 Posts)
  82. jaufgang (1 Post)

Tags for this Thread