1. #31
    Ext JS Premium Member
    Join Date
    May 2010
    Posts
    15
    Vote Rating
    0
    tfcoding is on a distinguished road

      0  

    Default


    Nothing, about this problem

  2. #32
    Sencha User
    Join Date
    Jul 2009
    Posts
    16
    Vote Rating
    1
    e-mike is on a distinguished road

      0  

    Default


    I had to swap the lines 32 and 33 in direct.php:

    if($output) $this->extdapi->output();
    $this->session->set_userdata(array('ext-direct-state' => $this->extdapi->getState()));

    to:

    $this->session->set_userdata(array('ext-direct-state' => $this->extdapi->getState()));
    if($output) $this->extdapi->output();

    Because if output is TRUE (default) then there is already a header send:

    r. 233 extdapi.php header('Content-Type: text/javascript');

    (I use the DB to store my sessions and it seems when setting userdata the header gets changed)

  3. #33
    Sencha User
    Join Date
    Jul 2009
    Posts
    16
    Vote Rating
    1
    e-mike is on a distinguished road

      0  

    Default


    @cherbert: did you solve your problem? I have the same now... ;-(

  4. #34
    Sencha User
    Join Date
    Jul 2009
    Posts
    16
    Vote Rating
    1
    e-mike is on a distinguished road

      0  

    Default


    OK, it took me a while but the problem described by cherbert is easy to fix.
    When the api is called (on the page) the state is made and set (session).
    But if some ajax magic happens the api is not called (which is good) and
    the set state by the api is not used cousin errors... So get the set state...
    The part that there is no set state then run api first was already there...

    controllers/Direct.php

    PHP Code:
        public function router()
        {
            
    $state $this->session->userdata('ext-direct-state');
            if ( ! 
    $state$this->api(FALSE);
            else 
    $this->ext_direct_api->setState($state);

            
    $this->load->library('ext_direct_router',
                array(
    'api' => $this->ext_direct_api));

            
    $this->ext_direct_router->dispatch();
            
    $this->ext_direct_router->getResponse(TRUE);
        } 

  5. #35
    Sencha User
    Join Date
    Jul 2009
    Posts
    16
    Vote Rating
    1
    e-mike is on a distinguished road

      0  

    Default


    I found a problem and have a fix (which took me again a while).
    If you want to use @formHandler you will keep getting errors...

    libraries/extdapi.php r.55

    PHP Code:
    $this->setFormAttribute($state['nameAttribute']);

    // must be

    $this->setNameAttribute($state['nameAttribute']); 
    YES YES YES now all three ext direct examples work!!!

    change:

    <script type="text/javascript" src="php/api.php"></script>

    to:

    <script type="text/javascript" src="/direct/api"></script>

    (this is the controller file at: controllers/Direct.php)

    And transform the two files Profile and TestAction in classes
    the way Echo, File, Time etc. is done.

  6. #36
    Sencha User
    Join Date
    Jul 2009
    Posts
    16
    Vote Rating
    1
    e-mike is on a distinguished road

      0  

    Default


    For those who are interested and want to fork the code, see:

    BitBucket: http://bit.ly/ckm19M

  7. #37
    Ext User
    Join Date
    Jan 2011
    Posts
    1
    Vote Rating
    0
    Gueifu is on a distinguished road

      0  

    Default


    I am going to look at both your suggestions and look for any good deals on these. Thanks again for the help.

  8. #38
    Sencha User
    Join Date
    Jun 2007
    Posts
    1
    Vote Rating
    0
    ReLexEd is on a distinguished road

      0  

    Default Updated for Codeigniter 2.0...

    Updated for Codeigniter 2.0...


    If anyone wants to use this under CodeIgniter 2.0, all you have to do is the following:

    ChangeIn controller/direct.php:
    Code:
    class Direct extends Controller {
    
    	function Direct()
    	{
    		parent::Controller();
    		$this->load->library('extdapi');
    		$this->load->library('extdcacheprovider', array('filePath' => 'cache/api_cache.txt'));
    	}
    
    Into:
    Code:
    
    class Direct extends CI_Controller {
    
    	function __construct()
    	{
    		parent::__construct();
    		$this->load->library('ext.direct/extdapi');
    		$this->load->library('ext.direct/extdcacheprovider', array('filePath' => 'cache/api_cache.txt'));
    	}
    
    Last edited by ReLexEd; 29 Apr 2011 at 4:03 AM. Reason: Code formatting

  9. #39
    Sencha User
    Join Date
    Dec 2009
    Posts
    5
    Vote Rating
    0
    RoyN is on a distinguished road

      0  

    Default


    Is this or any other library been updated?

    I wanted to use CI + Ext.Direct and having trouble with CI 2.0.2...

    Is anyone using this? Mind to share latest version? I even tried latest download from Mike's link...problems arise... (namely I got stuck trying to get ext.designer to validate the api url - i assume it is because it was returning JS instead of pure JSON)

  10. #40
    Sencha Premium Member vadimv's Avatar
    Join Date
    Sep 2010
    Location
    Chisinau, Moldova
    Posts
    642
    Vote Rating
    25
    vadimv will become famous soon enough vadimv will become famous soon enough

      0  

    Default


    I'm trying Mike's library, but I've got stuck and wonder whether anyone can help me. I see actions in provider, but when trying to use them I can't , because actions namespaces are not included in global namespace. Any suggestion would be greatly appreciated.

Turkiyenin en sevilen filmlerinin yer aldigi xnxx internet sitemiz olan ve porn sex tarzi bir site olan mobil porno izle sitemiz gercekten dillere destan bir durumda herkesin sevdigi bir site olarak tarihe gececege benziyor. Sitenin en belirgin ozelliklerinden birisi de Turkiyede gercekten kaliteli ve muntazam, duzenli porno izle siteleri olmamasidir. Bu yuzden iste. Ayrica en net goruntu kalitesine sahip adresinde yayinlanmaktadir. Mesela diğer sitelerimizden bahsedecek olursak, en iyi hd porno video arşivine sahip bir siteyiz. "The Best anal porn videos and slut anus, big asses movies set..." hd porno faketaxi