1. #1
    Sencha User
    Join Date
    Apr 2012
    Posts
    4
    Vote Rating
    0
    gund is on a distinguished road

      0  

    Default Ext.Msg.show - How determine what was clicked?

    Ext.Msg.show - How determine what was clicked?


    Hi!

    I`d like to answer a user for confirmation wiyh this code:
    Code:
    {Ext.Msg.show({
             title:'Logout',
             msg: 'Do you really want to logout?',
             buttons: Ext.Msg.YESNOCANCEL,
             icon: Ext.Msg.QUESTION,
             fn: function() {
    
                location.replace='http://....';// fire it if was pressed YES button
            }
        });}
    I tried to make function like this:
    Code:
    fn: function(btn) {
    if (btn == 'yes') {
    //redirect...
    }
    }
    but it doesn`t work

    So how can I built this function?
    Thank)

  2. #2
    Sencha User
    Join Date
    Mar 2012
    Posts
    21
    Vote Rating
    0
    nakul_sagar is on a distinguished road

      0  

    Default


    hope it helps you..

    handler: function () {
    Ext.Msg.confirm('',' Are you sure want to log off?', function(btn, text){
    if (btn == 'yes'){
    // redirect......
    }
    });
    }

  3. #3
    Sencha User
    Join Date
    Apr 2012
    Posts
    4
    Vote Rating
    0
    gund is on a distinguished road

      0  

    Default


    Thank you, but it doesn`t work too...
    Maybe there are another ways to solve this problem?

  4. #4
    Sencha User
    Join Date
    Apr 2012
    Posts
    4
    Vote Rating
    0
    gund is on a distinguished road

      0  

    Default


    Ok)
    I did it!
    Here is solution if you need:
    Code:
    	{Ext.Msg.show({
    	     title:'Logout',
    	     msg: '
    Do you really want to logout?
    ', buttons: Ext.Msg.YESNO, icon: Ext.Msg.QUESTION, fn: function(btn) { if(btn == 'yes') location.href='http:/...'; } });}

Thread Participants: 1

Tags for this Thread

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