1. #1
    Sencha User
    Join Date
    Mar 2012
    Posts
    17
    Vote Rating
    0
    tadhg is on a distinguished road

      0  

    Default Unanswered: How to make the Ext.Msg.prompt input field a password?

    Unanswered: How to make the Ext.Msg.prompt input field a password?


    I'm pulling my hair out trying to find out how to set the Ext.Msg.prompt input field to a password.

    I can do it with a component query if I find the texfield id with the Chrome dev tools. However, the framework dynamically sets these ids, so it tends to change during the running of the application, and then breaks my code.

    If anyone knows how this can be done, I'd really appreciate some help.

    Tadhg

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

      0  

    Default


    Really need to get to the bottom of this, please help!!

  3. #3
    Sencha User
    Join Date
    Mar 2012
    Posts
    17
    Vote Rating
    0
    tadhg is on a distinguished road

      0  

    Default


    Can anyone out there shed some light on this? Really need to deploy my app and this is the last outstanding task. Pleeeeease help....

  4. #4
    Ext GWT Premium Member
    Join Date
    May 2010
    Location
    Ashburn, Virginia
    Posts
    48
    Answers
    8
    Vote Rating
    2
    darren102 is on a distinguished road

      0  

    Default


    For the prompt config property you can just pass in an type of password and it should become a password field.

    Code:
    config:{
        prompt:{
            xtype:'passwordfield'
        }
    }
    This should create it as a password field. If this does not work, then you will have to use the component query possibly providing a unique selector to the message box on creation that you will be able to select from.

  5. #5
    Sencha User
    Join Date
    Mar 2012
    Posts
    17
    Vote Rating
    0
    tadhg is on a distinguished road

      0  

    Default


    Hi Darren, thanks for your reply, I really appreciate it. I tried a few version of your suggestion but to no avail. Here's my code, perhaps it can shed some light:

    Code:
    var msg = Ext.Msg.prompt("Send Database contents", "Please enter the admin password", function (btn, inputValue) {
                if (btn == "ok") {
                    Ext.Ajax.request({
                        url: 'email-database.php?password=' + inputValue
                    });
                }
            });
    And with your suggestion:

    Code:
    var msg = Ext.Msg.prompt({
                title: "Email Database contents",
                message: "Please enter the admin password",
                fn: function (btn, inputValue) {
                    if (btn == "ok") {
                        Ext.Ajax.request({
                            url: 'email-database.php?password=' + inputValue
                        });
                    }
                },
                config: {
                    prompt: {
                        xtype: 'passwordfield'
                    }
                }
            });
    Finally I took a stab at this:
    Code:
    msg.getPrompt().config.component.type = 'password';
    Still no joy. Any thoughts based on what I'm doing above?

  6. #6
    Ext GWT Premium Member
    Join Date
    May 2010
    Location
    Ashburn, Virginia
    Posts
    48
    Answers
    8
    Vote Rating
    2
    darren102 is on a distinguished road

      0  

    Default


    The code below will display with the password field in the application.

    Code:
            Ext.Msg.prompt(
                "Email Database contents",
                "Please enter the admin password",
                function (btn, inputValue) {
                    if (btn == "ok") {
                        Ext.Ajax.request({
                            url:'email-database.php?password=' + inputValue
                        });
                    }
                },
                null,
                false,
                null,
                {xtype:'passwordfield'});

  7. #7
    Sencha User
    Join Date
    Mar 2012
    Posts
    17
    Vote Rating
    0
    tadhg is on a distinguished road

      0  

    Default


    Darren you're a life saver, works like a charm! I'm kicking myself now that I understand how you did it. Thank you so much mate.

  8. #8
    Sencha User
    Join Date
    Oct 2012
    Posts
    1
    Vote Rating
    0
    Luis Fernando is on a distinguished road

      0  

    Default Hola

    Hola


    Gracias me funciono con el ultimo codigo

Thread Participants: 2

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